2dog.xunit
4.7.0.31
See the version list below for details.
dotnet add package 2dog.xunit --version 4.7.0.31
NuGet\Install-Package 2dog.xunit -Version 4.7.0.31
<PackageReference Include="2dog.xunit" Version="4.7.0.31" />
<PackageVersion Include="2dog.xunit" Version="4.7.0.31" />
<PackageReference Include="2dog.xunit" />
paket add 2dog.xunit --version 4.7.0.31
#r "nuget: 2dog.xunit, 4.7.0.31"
#:package 2dog.xunit@4.7.0.31
#addin nuget:?package=2dog.xunit&version=4.7.0.31
#tool nuget:?package=2dog.xunit&version=4.7.0.31
2dog.xunit
xUnit collection definitions for testing Godot applications with 2dog.
The fixtures themselves (GodotFixture, GodotHeadlessFixture, GodotFixtureBase) ship in the
2dog package, in the twodog.fixture namespace. This package adds the xUnit-specific glue on
top of them.
What it provides
GodotCollection– binds the full (rendering)GodotFixtureGodotHeadlessCollection– bindsGodotHeadlessFixture(use this for CI)
Both set DisableParallelization = true, which is required because Godot allows only one instance
per process.
How it works
xUnit only discovers [CollectionDefinition] classes that live in the test assembly – a
definition shipped in a referenced DLL is silently ignored (its DisableParallelization and
ICollectionFixture<T> are not applied). To make the collections actually work, this package ships
them as compile-in source: a build/2dog.xunit.targets file adds the collection definitions to
your test project's compilation, so they end up in your test assembly where xUnit can find them.
You therefore do not write your own collection definition – just reference the package and use the collections directly.
Usage
using Godot;
using twodog.fixture; // GodotHeadlessFixture
using twodog.xunit; // GodotHeadlessCollection
using Xunit;
[Collection<GodotHeadlessCollection>]
public class MyTests(GodotHeadlessFixture godot)
{
[Fact]
public void EngineStarts()
{
Assert.NotNull(godot.Tree);
}
}
Custom fixtures
Need a different Godot configuration? Subclass GodotFixtureBase (from the 2dog package) and
write a one-line collection for it in your own test project:
using twodog.fixture;
using Xunit;
public class GodotOpenGl3Fixture() : GodotFixtureBase("--display-driver", "opengl3");
[CollectionDefinition(nameof(GodotOpenGl3Collection), DisableParallelization = true)]
public class GodotOpenGl3Collection : ICollectionFixture<GodotOpenGl3Fixture>;
Learn more about Target Frameworks and .NET Standard.
-
net8.0
- 2dog (>= 4.7.0.31)
- xunit.v3.extensibility.core (>= 3.2.2)
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 |
|---|---|---|
| 4.7.1.51 | 41 | 7/22/2026 |
| 4.7.1.50 | 42 | 7/22/2026 |
| 4.7.1.49 | 113 | 7/19/2026 |
| 4.7.1.48 | 88 | 7/19/2026 |
| 4.7.1.46 | 119 | 7/17/2026 |
| 4.7.1.45 | 100 | 7/15/2026 |
| 4.7.1.44 | 93 | 7/15/2026 |
| 4.7.1.43 | 91 | 7/15/2026 |
| 4.7.0.41 | 97 | 7/14/2026 |
| 4.7.0.40 | 89 | 7/14/2026 |
| 4.7.0.39 | 93 | 7/14/2026 |
| 4.7.0.38 | 107 | 7/13/2026 |
| 4.7.0.37 | 100 | 7/13/2026 |
| 4.7.0.36 | 105 | 7/13/2026 |
| 4.7.0.35 | 106 | 7/13/2026 |
| 4.7.0.34 | 101 | 7/13/2026 |
| 4.7.0.32 | 107 | 7/12/2026 |
| 4.7.0.31 | 102 | 7/12/2026 |
| 4.7.0.30 | 103 | 7/12/2026 |
| 4.7.0.29 | 114 | 7/12/2026 |