RevitDevTool.TestAdapter 0.0.6

There is a newer version of this package available.
See the version list below for details.
dotnet add package RevitDevTool.TestAdapter --version 0.0.6
                    
NuGet\Install-Package RevitDevTool.TestAdapter -Version 0.0.6
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="RevitDevTool.TestAdapter" Version="0.0.6">
  <PrivateAssets>all</PrivateAssets>
  <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="RevitDevTool.TestAdapter" Version="0.0.6" />
                    
Directory.Packages.props
<PackageReference Include="RevitDevTool.TestAdapter">
  <PrivateAssets>all</PrivateAssets>
  <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add RevitDevTool.TestAdapter --version 0.0.6
                    
#r "nuget: RevitDevTool.TestAdapter, 0.0.6"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package RevitDevTool.TestAdapter@0.0.6
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=RevitDevTool.TestAdapter&version=0.0.6
                    
Install as a Cake Addin
#tool nuget:?package=RevitDevTool.TestAdapter&version=0.0.6
                    
Install as a Cake Tool

RevitDevTool.TestAdapter

Microsoft Testing Platform adapter that runs tests inside a CAD/BIM host. Requires RevitDevTool.

Currently supports NUnit and TUnit only. Pin the framework in the test project — the adapter does not pull either. It depends on Microsoft.Testing.Platform.MSBuild 2.4.0; do not add or override it. TUnit 1.66.27 and Microsoft.Testing.Platform 2.4.0 are a pair — pin both.

Package Version
NUnit 4.6.1
TUnit 1.66.27
Microsoft.Testing.Platform.MSBuild 2.4.0

NUnit and TUnit both work with every host below. Set HostName and HostVersion to the version you run. Include a compile-only host API package (discovery needs it). Do not copy host API DLLs next to the test output.

HostName: Revit, AutoCad, Civil3D, Plant3D, AcadArch, AcadMech, AcadElec, AcadMep, AcadMap3D.

Default engine is NUnit. Set TestingFramework to tunit to use TUnit. Do not use .runsettings.

NUnit (default)

<PropertyGroup>
  <HostName>Revit</HostName>
  <HostVersion>2025</HostVersion>
  <ForceLaunch>false</ForceLaunch>
  <PerTestTimeout>60</PerTestTimeout>
  <LaunchTimeout>180</LaunchTimeout>
</PropertyGroup>
<ItemGroup>
  <PackageReference Include="RevitDevTool.TestAdapter" Version="0.0.6" />
  <PackageReference Include="NUnit" Version="4.6.1" />
  <PackageReference Include="Revit_All_Main_Versions_API_x64" Version="2025.0.*"
    IncludeAssets="build; compile" PrivateAssets="All" />
</ItemGroup>

TUnit

<PropertyGroup>
  <HostName>Revit</HostName>
  <HostVersion>2025</HostVersion>
  <ForceLaunch>false</ForceLaunch>
  <PerTestTimeout>60</PerTestTimeout>
  <LaunchTimeout>180</LaunchTimeout>
  <TestingFramework>tunit</TestingFramework>  
</PropertyGroup>
<ItemGroup>
  <PackageReference Include="RevitDevTool.TestAdapter" Version="0.0.6" />
  <PackageReference Include="TUnit" Version="1.66.27" />
  <PackageReference Include="Revit_All_Main_Versions_API_x64" Version="2025.0.*"
    IncludeAssets="build; compile" PrivateAssets="All" />
</ItemGroup>

Keep a global.json next to the test project:

{
  "sdk": { "version": "10.0.0", "rollForward": "latestMinor" },
  "test": { "runner": "Microsoft.Testing.Platform" }
}
cd path/to/Host.Tests
dotnet test --project Host.Tests.csproj -c Debug --filter MethodName

--filter is a test method name or substring. Always run dotnet test from the folder that contains that global.json.

Product Compatible and additional computed target framework versions.
.NET net8.0-windows7.0 is compatible.  net9.0-windows was computed.  net10.0-windows was computed.  net10.0-windows7.0 is compatible. 
.NET Framework net48 is compatible.  net481 was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.1.1 81 9/21/2026
0.1.0 92 9/13/2026
0.0.6 104 9/8/2026
0.0.5 96 9/8/2026
0.0.4 95 9/4/2026
0.0.3 105 8/23/2026
0.0.2 109 8/20/2026
0.0.1 109 8/18/2026