Skip to content

Commit

Permalink
removed dotnet 5
Browse files Browse the repository at this point in the history
fixed some nullable issues
removed configure await from 2 tests
  • Loading branch information
RagingKore committed Nov 6, 2023
1 parent 2fa606c commit 5ac5b1a
Show file tree
Hide file tree
Showing 9 changed files with 16 additions and 20 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/base.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
strategy:
fail-fast: false
matrix:
framework: [net5.0, net6.0, net7.0]
framework: [net6.0, net7.0]
os: [ubuntu-latest]
test: [Streams, PersistentSubscriptions, Operations, UserManagement, ProjectionManagement]
configuration: [release]
Expand All @@ -33,7 +33,6 @@ jobs:
uses: actions/setup-dotnet@v3
with:
dotnet-version: |
5.0.x
6.0.x
7.0.x
- name: Compile
Expand Down
10 changes: 3 additions & 7 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
strategy:
fail-fast: false
matrix:
framework: [ net5.0, net6.0, net7.0 ]
framework: [ net6.0, net7.0 ]
os: [ ubuntu-latest, windows-latest ]
runs-on: ${{ matrix.os }}
name: scan-vulnerabilities/${{ matrix.os }}/${{ matrix.framework }}
Expand All @@ -25,7 +25,6 @@ jobs:
uses: actions/setup-dotnet@v3
with:
dotnet-version: |
5.0.x
6.0.x
7.0.x
- name: Scan for Vulnerabilities
Expand All @@ -43,7 +42,7 @@ jobs:
strategy:
fail-fast: false
matrix:
framework: [ net5.0, net6.0, net7.0 ]
framework: [ net6.0, net7.0 ]
services:
esdb:
image: ghcr.io/eventstore/eventstore:lts
Expand All @@ -62,7 +61,6 @@ jobs:
uses: actions/setup-dotnet@v3
with:
dotnet-version: |
5.0.x
6.0.x
7.0.x
- name: Compile
Expand All @@ -79,7 +77,7 @@ jobs:
strategy:
fail-fast: false
matrix:
framework: [net5.0, net6.0, net7.0]
framework: [net6.0, net7.0]
os: [ubuntu-latest, windows-latest]
configuration: [release]
runs-on: ${{ matrix.os }}
Expand All @@ -94,7 +92,6 @@ jobs:
uses: actions/setup-dotnet@v3
with:
dotnet-version: |
5.0.x
6.0.x
7.0.x
- name: Compile
Expand Down Expand Up @@ -132,7 +129,6 @@ jobs:
uses: actions/setup-dotnet@v3
with:
dotnet-version: |
5.0.x
6.0.x
7.0.x
- name: Dotnet Pack
Expand Down
2 changes: 1 addition & 1 deletion Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project>
<PropertyGroup>
<TargetFrameworks>net5.0;net6.0;net7.0</TargetFrameworks>
<TargetFrameworks>net6.0;net7.0</TargetFrameworks>
<Platform>x64</Platform>
<GenerateAssemblyInfo>true</GenerateAssemblyInfo>
<Nullable>enable</Nullable>
Expand Down
2 changes: 1 addition & 1 deletion samples/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
<Nullable>enable</Nullable>
<NullableContextOptions>enable</NullableContextOptions>
<OutputType>Exe</OutputType>
<TargetFrameworks>net5.0;net6.0;net7.0</TargetFrameworks>
<TargetFrameworks>net6.0;net7.0</TargetFrameworks>
</PropertyGroup>
</Project>
11 changes: 6 additions & 5 deletions test/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,24 @@
<Import Project="$([MSBuild]::GetPathOfFileAbove('Directory.Build.props', '$(MSBuildThisFileDirectory)../'))" />
<PropertyGroup>
<EmitCompilerGeneratedFiles>true</EmitCompilerGeneratedFiles>
<NoWarn>xUnit1031</NoWarn>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="AutoFixture.Idioms" Version="4.18.0" />
<PackageReference Include="AutoFixture.Xunit2" Version="4.18.0" />
<PackageReference Include="Ductus.FluentDocker" Version="2.10.59" />
<PackageReference Include="GitHubActionsTestLogger" Version="2.0.1"/>
<PackageReference Include="GitHubActionsTestLogger" Version="2.3.3"/>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.7.2"/>
<PackageReference Include="Polly" Version="8.1.0" />
<PackageReference Include="Serilog" Version="3.0.1"/>
<PackageReference Include="Serilog.AspNetCore" Version="7.0.0"/>
<PackageReference Include="Serilog.Sinks.Observable" Version="2.0.2"/>
<PackageReference Include="Serilog.Sinks.Seq" Version="5.1.1"/>
<PackageReference Include="Serilog.Sinks.Seq" Version="5.2.3"/>
<PackageReference Include="System.Net.Http" Version="4.3.4"/>
<PackageReference Include="System.Reactive" Version="5.0.0"/>
<PackageReference Include="System.Reactive" Version="6.0.0"/>
<PackageReference Include="System.Text.RegularExpressions" Version="4.3.1"/>
<PackageReference Include="xunit" Version="2.4.1"/>
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.3">
<PackageReference Include="xunit" Version="2.6.1"/>
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.5">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ public read_all_events_forward_with_linkto_passed_max_count(Fixture fixture) {

[Fact]
public void one_event_is_read() {
Assert.Single(_fixture.Events);
Assert.Single(_fixture.Events ?? Array.Empty<ResolvedEvent>());
}

public class Fixture : EventStoreClientFixture {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ protected read_events_linked_to_deleted_stream(Fixture fixture) {

[Fact]
public void one_event_is_read() {
Assert.Single(_fixture.Events);
Assert.Single(_fixture.Events ?? Array.Empty<ResolvedEvent>());
}

[Fact]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ public void setting_options_on_clone_should_not_modify_original() {
clonedOptions.BatchAppendSize = int.MaxValue;

Assert.Equal(options.BatchAppendSize, EventStoreClientOperationOptions.Default.BatchAppendSize);
Assert.Equal(clonedOptions.BatchAppendSize, int.MaxValue);
Assert.Equal(int.MaxValue, clonedOptions.BatchAppendSize);
}
}
}
2 changes: 1 addition & 1 deletion test/EventStore.Client.Tests/GossipChannelSelectorTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public async Task ThrowsWhenDiscoveryFails() {
var sut = new GossipChannelSelector(settings, channelCache, new BadGossipClient());

var ex = await Assert.ThrowsAsync<DiscoveryException>(async () =>
await sut.SelectChannelAsync(cancellationToken: default).ConfigureAwait(false));
await sut.SelectChannelAsync(cancellationToken: default));

Assert.Equal(3, ex.MaxDiscoverAttempts);
}
Expand Down

0 comments on commit 5ac5b1a

Please sign in to comment.