Skip to content

Commit 33b4ea6

Browse files
authored
Merge pull request #1 from DecSmith42/chore-deps
chore: Update deps and add MacOS and Windows to tests
2 parents 54aee36 + 61a1a2e commit 33b4ea6

File tree

6 files changed

+33
-9
lines changed

6 files changed

+33
-9
lines changed

.github/workflows/Build.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,10 @@ jobs:
5454
path: "${{ github.workspace }}/.github/publish/DecSm.Extensions.Logging.File"
5555

5656
TestFileLogging:
57-
runs-on: ubuntu-latest
57+
strategy:
58+
matrix:
59+
job-runs-on: [ windows-latest, ubuntu-latest, macos-latest ]
60+
runs-on: ${{ matrix.job-runs-on }}
5861
steps:
5962

6063
- name: Checkout
@@ -68,11 +71,14 @@ jobs:
6871
- name: TestFileLogging
6972
id: TestFileLogging
7073
run: dotnet run --project _atom/_atom.csproj TestFileLogging --skip --headless
74+
env:
75+
job-runs-on: ${{ matrix.job-runs-on }}
76+
build-slice: ${{ matrix.job-runs-on }}
7177

7278
- name: Upload DecSm.Extensions.Logging.File.UnitTests
7379
uses: actions/upload-artifact@v4
7480
with:
75-
name: DecSm.Extensions.Logging.File.UnitTests
81+
name: DecSm.Extensions.Logging.File.UnitTests-${{ matrix.job-runs-on }}
7682
path: "${{ github.workspace }}/.github/publish/DecSm.Extensions.Logging.File.UnitTests"
7783

7884
PushToNuget:

.github/workflows/Validate.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,10 @@ jobs:
4545
run: dotnet run --project _atom/_atom.csproj PackFileLogging --skip --headless
4646

4747
TestFileLogging:
48-
runs-on: ubuntu-latest
48+
strategy:
49+
matrix:
50+
job-runs-on: [ windows-latest, ubuntu-latest, macos-latest ]
51+
runs-on: ${{ matrix.job-runs-on }}
4952
steps:
5053

5154
- name: Checkout
@@ -59,9 +62,12 @@ jobs:
5962
- name: TestFileLogging
6063
id: TestFileLogging
6164
run: dotnet run --project _atom/_atom.csproj TestFileLogging --skip --headless
65+
env:
66+
job-runs-on: ${{ matrix.job-runs-on }}
67+
build-slice: ${{ matrix.job-runs-on }}
6268

6369
- name: Upload DecSm.Extensions.Logging.File.UnitTests
6470
uses: actions/upload-artifact@v4
6571
with:
66-
name: DecSm.Extensions.Logging.File.UnitTests
72+
name: DecSm.Extensions.Logging.File.UnitTests-${{ matrix.job-runs-on }}
6773
path: "${{ github.workspace }}/.github/publish/DecSm.Extensions.Logging.File.UnitTests"

DecSm.Extensions.Logging.File.UnitTests/DecSm.Extensions.Logging.File.UnitTests.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@
1616
<PackageReference Include="NUnit3TestAdapter" Version="4.6.0"/>
1717
<PackageReference Include="Shouldly" Version="4.2.1"/>
1818
<PackageReference Include="Spectre.Console.Testing" Version="0.49.1"/>
19-
<PackageReference Include="System.IO.Abstractions" Version="21.1.7" />
20-
<PackageReference Include="TestableIO.System.IO.Abstractions.TestingHelpers" Version="21.1.7"/>
19+
<PackageReference Include="System.IO.Abstractions" Version="22.0.14" />
20+
<PackageReference Include="TestableIO.System.IO.Abstractions.TestingHelpers" Version="22.0.14"/>
2121
<PackageReference Include="Verify.NUnit" Version="28.5.0"/>
2222
</ItemGroup>
2323

DecSm.Extensions.Logging.File/DecSm.Extensions.Logging.File.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
<ItemGroup>
99
<PackageReference Include="JetBrains.Annotations" Version="2024.3.0"/>
1010
<PackageReference Include="Microsoft.Extensions.Logging.Configuration" Version="9.0.4"/>
11-
<PackageReference Include="System.IO.Abstractions" Version="21.1.7"/>
11+
<PackageReference Include="System.IO.Abstractions" Version="22.0.14" />
1212
</ItemGroup>
1313

1414
<!-- Dotnet Standard 2.0 Packages-->

_atom/Build.cs

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,13 @@ internal partial class Build : DefaultBuildDefinition,
2222
Triggers = [GitPullRequestTrigger.IntoMain, ManualTrigger.Empty],
2323
StepDefinitions =
2424
[
25-
Commands.SetupBuildInfo, Commands.PackFileLogging.WithSuppressedArtifactPublishing, Commands.TestFileLogging,
25+
Commands.SetupBuildInfo,
26+
Commands.PackFileLogging.WithSuppressedArtifactPublishing,
27+
Commands
28+
.TestFileLogging
29+
.WithAddedMatrixDimensions(new MatrixDimension(nameof(IJobRunsOn.JobRunsOn),
30+
[IJobRunsOn.WindowsLatestTag, IJobRunsOn.UbuntuLatestTag, IJobRunsOn.MacOsLatestTag]))
31+
.WithAddedOptions(GithubRunsOn.SetByMatrix),
2632
],
2733
WorkflowTypes = [Github.WorkflowType],
2834
},
@@ -33,7 +39,11 @@ internal partial class Build : DefaultBuildDefinition,
3339
[
3440
Commands.SetupBuildInfo,
3541
Commands.PackFileLogging,
36-
Commands.TestFileLogging,
42+
Commands
43+
.TestFileLogging
44+
.WithAddedMatrixDimensions(new MatrixDimension(nameof(IJobRunsOn.JobRunsOn),
45+
[IJobRunsOn.WindowsLatestTag, IJobRunsOn.UbuntuLatestTag, IJobRunsOn.MacOsLatestTag]))
46+
.WithAddedOptions(GithubRunsOn.SetByMatrix),
3747
Commands.PushToNuget.WithAddedOptions(WorkflowSecretInjection.Create(Params.NugetApiKey)),
3848
Commands.PushToRelease.WithGithubTokenInjection(),
3949
],

_atom/_usings.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,7 @@
55
global using DecSm.Atom.Module.GitVersion;
66
global using DecSm.Atom.Params;
77
global using DecSm.Atom.Workflows.Definition;
8+
global using DecSm.Atom.Workflows.Definition.Command;
89
global using DecSm.Atom.Workflows.Definition.Options;
910
global using DecSm.Atom.Workflows.Definition.Triggers;
11+
global using DecSm.Atom.Workflows.Options;

0 commit comments

Comments
 (0)