Skip to content

Commit 44da738

Browse files
committed
Update to latest release versions
1 parent 6adabc0 commit 44da738

File tree

5 files changed

+9
-24
lines changed

5 files changed

+9
-24
lines changed

AssemblyFixtureExample/Samples.cs

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
using System;
1+
#pragma warning disable xUnit1041 // This sample uses an alternate fixture source that xUnit1041 doesn't understand
2+
3+
using System;
24
using Xunit;
35

46
// The custom test framework enables the support

AssertSource/AssertionLibrary/AssertionLibrary.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
As noted in https://github.com/xunit/assert.xunit#annotations we enable all the supported flags for the newest
66
assertion library features that are supported for v2.
77
-->
8-
<DefineConstants>$(DefineConstants);XUNIT_IMMUTABLE_COLLECTIONS;XUNIT_NULLABLE;XUNIT_SPAN;XUNIT_VALUETASK</DefineConstants>
8+
<DefineConstants>$(DefineConstants);XUNIT_IMMUTABLE_COLLECTIONS;XUNIT_NULLABLE;XUNIT_SPAN</DefineConstants>
99
<Nullable>enable</Nullable>
1010
<TargetFramework>net6.0</TargetFramework>
1111
</PropertyGroup>

AssertSource/ExampleTests/UnitTest1.cs

-17
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
using System;
2-
using System.Threading.Tasks;
32
using Xunit;
43

54
namespace ExampleTests;
@@ -31,20 +30,4 @@ public void SpanExample()
3130

3231
Assert.Equal(x, y);
3332
}
34-
35-
// Important: although the assertion library enables support for ValueTask, your
36-
// test methods must still return void or Task; if you return ValueTask, the behavior
37-
// is undefined (they will likely silently pass rather than fail appropriately). This
38-
// is because support for ValueTask-based test methods is not supported with the
39-
// v2 core framework.
40-
[Fact]
41-
public async Task ValueTaskExample()
42-
{
43-
int[] values = new[] { 4, 5 };
44-
45-
await Assert.AllAsync(
46-
values,
47-
value => Assert.IsEvenAsync(value)
48-
);
49-
}
5033
}

Directory.Build.props

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
<Project>
22

33
<PropertyGroup>
4-
<MicrosoftNetTestSdkVersion>17.6.2</MicrosoftNetTestSdkVersion>
5-
<XunitAnalyzersVersion>1.2.0-pre.27</XunitAnalyzersVersion>
6-
<XunitV2Version>2.5.0-pre.37</XunitV2Version>
7-
<XunitRunnerVSVersion>2.5.0-pre.22</XunitRunnerVSVersion>
4+
<MicrosoftNetTestSdkVersion>17.8.0</MicrosoftNetTestSdkVersion>
5+
<XunitAnalyzersVersion>1.8.0</XunitAnalyzersVersion>
6+
<XunitV2Version>2.6.4</XunitV2Version>
7+
<XunitRunnerVSVersion>2.5.6</XunitRunnerVSVersion>
88
</PropertyGroup>
99

1010
</Project>

NuGet.Config

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
<packageSources>
44
<clear />
55
<add key="api.nuget.org" value="https://api.nuget.org/v3/index.json" protocolVersion="3" />
6-
<add key="myget.org/F/xunit" value="https://www.myget.org/F/xunit/api/v3/index.json" protocolVersion="3" />
6+
<add key="feedz.io/xunit/xunit" value="https://f.feedz.io/xunit/xunit/nuget/index.json" protocolVersion="3" />
77
</packageSources>
88
</configuration>

0 commit comments

Comments
 (0)