Skip to content

Commit b220157

Browse files
committed
Feat: CodeOfChaos.Testing
1 parent bbe7464 commit b220157

File tree

5 files changed

+49
-3
lines changed

5 files changed

+49
-3
lines changed

.github/workflows/release.yml

+7-3
Original file line numberDiff line numberDiff line change
@@ -21,19 +21,23 @@ jobs:
2121
dotnet-version: '9.x'
2222

2323
- name: Restore dependencies
24-
run: dotnet restore CodeOfChaos.Testing.TUnit.sln
24+
run: dotnet restore CodeOfChaos.Testing.sln
2525

2626
- name: Build
27-
run: dotnet build CodeOfChaos.Testing.TUnit.sln --configuration Release --no-restore
27+
run: dotnet build CodeOfChaos.Testing.sln --configuration Release --no-restore
2828

2929
# Ensure that the tests must pass
3030
# The job will fail automatically if any test fails because `dotnet test` exits with a non-zero code
31-
- name: Run tests - Extensions
31+
# - name: Run tests - Testing
32+
# run: dotnet run -c Release --no-restore --no-build
33+
# working-directory: "tests/Tests.CodeOfChaos.Testing"
34+
- name: Run tests - Testing.TUnit
3235
run: dotnet run -c Release --no-restore --no-build
3336
working-directory: "tests/Tests.CodeOfChaos.Testing.TUnit"
3437

3538
- name: Publish to NuGet
3639
env:
3740
NUGET_API_KEY: ${{ secrets.NUGET_API_KEY }}
3841
run: |
42+
dotnet nuget push src/CodeOfChaos.Testing/bin/Release/*.nupkg --api-key $NUGET_API_KEY --source https://api.nuget.org/v3/index.json --skip-duplicate
3943
dotnet nuget push src/CodeOfChaos.Testing.TUnit/bin/Release/*.nupkg --api-key $NUGET_API_KEY --source https://api.nuget.org/v3/index.json --skip-duplicate

CodeOfChaos.Testing.TUnit.sln renamed to CodeOfChaos.Testing.sln

+7
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Tools.CodeOfChaos.Testing.T
1414
EndProject
1515
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CodeOfChaos.Testing", "src\CodeOfChaos.Testing\CodeOfChaos.Testing.csproj", "{AADC19E6-F488-4691-97FF-D6CD37B78848}"
1616
EndProject
17+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Tests.CodeOfChaos.Testing", "tests\Tests.CodeOfChaos.Testing\Tests.CodeOfChaos.Testing.csproj", "{A65111CE-0DD8-42A9-B467-5235312D1C20}"
18+
EndProject
1719
Global
1820
GlobalSection(SolutionConfigurationPlatforms) = preSolution
1921
Debug|Any CPU = Debug|Any CPU
@@ -36,11 +38,16 @@ Global
3638
{AADC19E6-F488-4691-97FF-D6CD37B78848}.Debug|Any CPU.Build.0 = Debug|Any CPU
3739
{AADC19E6-F488-4691-97FF-D6CD37B78848}.Release|Any CPU.ActiveCfg = Release|Any CPU
3840
{AADC19E6-F488-4691-97FF-D6CD37B78848}.Release|Any CPU.Build.0 = Release|Any CPU
41+
{A65111CE-0DD8-42A9-B467-5235312D1C20}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
42+
{A65111CE-0DD8-42A9-B467-5235312D1C20}.Debug|Any CPU.Build.0 = Debug|Any CPU
43+
{A65111CE-0DD8-42A9-B467-5235312D1C20}.Release|Any CPU.ActiveCfg = Release|Any CPU
44+
{A65111CE-0DD8-42A9-B467-5235312D1C20}.Release|Any CPU.Build.0 = Release|Any CPU
3945
EndGlobalSection
4046
GlobalSection(NestedProjects) = preSolution
4147
{26284571-0E09-4BAF-8C2B-DF87DCC1BA0B} = {8DD280D4-1E14-4D5E-AFE6-58DD8F079DCC}
4248
{64B26DED-68C3-47FF-B409-1C8FAD4F9176} = {197E72AD-DEAB-4350-AFC3-A3BB38720BF5}
4349
{ADEADD97-0AFA-4D9E-970B-9FFB932949B3} = {AF1A203C-6EF1-440E-BB3C-55B1DBFE9C19}
4450
{AADC19E6-F488-4691-97FF-D6CD37B78848} = {197E72AD-DEAB-4350-AFC3-A3BB38720BF5}
51+
{A65111CE-0DD8-42A9-B467-5235312D1C20} = {8DD280D4-1E14-4D5E-AFE6-58DD8F079DCC}
4552
EndGlobalSection
4653
EndGlobal

src/CodeOfChaos.Testing/CodeOfChaos.Testing.csproj

+21
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,29 @@
44
<TargetFramework>net9.0</TargetFramework>
55
<ImplicitUsings>enable</ImplicitUsings>
66
<Nullable>enable</Nullable>
7+
8+
<!-- Main package name -->
9+
<PackageId>CodeOfChaos.Testing</PackageId>
10+
<Version>0.7.0</Version>
11+
<Authors>Anna Sas</Authors>
12+
<Description>A small library housing some common frameworks used for testing CodeOfChaos stuff</Description>
13+
<PackageProjectUrl>https://github.com/code-of-chaos/cs_code-of_chaos-testing-tunit</PackageProjectUrl>
14+
<PackageTags>extensions testing</PackageTags>
15+
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
16+
<PublishRepositoryUrl>true</PublishRepositoryUrl>
17+
<IncludeSymbols>true</IncludeSymbols>
18+
<DebugType>embedded</DebugType>
19+
<PackageLicenseFile>LICENSE</PackageLicenseFile>
20+
<PackageReadmeFile>README.md</PackageReadmeFile>
21+
<PackageIcon>icon.png</PackageIcon>
722
</PropertyGroup>
823

24+
<ItemGroup>
25+
<None Include="../../LICENSE" Pack="true" PackagePath="" Visible="false" />
26+
<None Include="../../README.md" Pack="true" PackagePath="" Visible="false" />
27+
<None Include="../../assets/icon.png" Pack="true" PackagePath="" Visible="false" />
28+
</ItemGroup>
29+
930
<ItemGroup>
1031
<PackageReference Include="JetBrains.Annotations" Version="2024.3.0"/>
1132
<PackageReference Include="Microsoft.CodeAnalysis" Version="4.12.0" />

src/Tools.CodeOfChaos.Testing.TUnit/Program.cs

+1
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ public static async Task Main(string[] args) {
2222
// Sometimes CLI params is not the answer.
2323
// Code is the true saviour
2424
string projects = string.Join(";",
25+
"CodeOfChaos.Testing",
2526
"CodeOfChaos.Testing.TUnit"
2627
);
2728

Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<Project Sdk="Microsoft.NET.Sdk">
2+
3+
<PropertyGroup>
4+
<TargetFramework>net9.0</TargetFramework>
5+
<ImplicitUsings>enable</ImplicitUsings>
6+
<Nullable>enable</Nullable>
7+
</PropertyGroup>
8+
9+
<ItemGroup>
10+
<PackageReference Include="TUnit" Version="0.13.3" />
11+
</ItemGroup>
12+
13+
</Project>

0 commit comments

Comments
 (0)