Skip to content

Commit

Permalink
Continue csharp port
Browse files Browse the repository at this point in the history
  • Loading branch information
LivInTheLookingGlass committed Jun 25, 2024
1 parent 396380b commit e721542
Show file tree
Hide file tree
Showing 17 changed files with 1,281 additions and 12 deletions.
22 changes: 19 additions & 3 deletions .github/workflows/on_push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,10 +75,10 @@ jobs:
steps:
- uses: actions/checkout@v3

- name: Use Node.js ${{ matrix.version }}
- name: Use Node.js 22
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.version }}
node-version: 22
cache: 'npm'
cache-dependency-path: 'javascript/package-lock.json'

Expand Down Expand Up @@ -211,10 +211,26 @@ jobs:
with:
dotnet-version: ${{ matrix.net_version }}
cache: true
cache-dependency-path: 'csharp/packages.lock.json'
cache-dependency-path: 'csharp/*/packages.lock.json'

- name: Dependencies
run: make csdependencies

- name: Run Tests
run: make cstest

csharp-lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Setup .NET 8
uses: actions/setup-dotnet@v3
with:
dotnet-version: 8
cache: true
cache-dependency-path: 'csharp/*/packages.lock.json'

- name: Run Linter
run: make cslint

5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,8 @@ javascript/node_modules/**
**/*.exe
**/build/**
venv/**
**.dll
**.pdb
csharp/*/obj
csharp/*/bin
**/TestResults
5 changes: 5 additions & 0 deletions .stignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,8 @@ javascript/node_modules/**
**/*.exe
**/build/**
venv/**
**.dll
**.pdb
csharp/*/obj
csharp/*/bin
**/TestResults
25 changes: 25 additions & 0 deletions Euler.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.5.002.0
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "csharp", "csharp\csharp.csproj", "{83B915D6-6A7D-4946-8EF2-16E2C154A555}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{83B915D6-6A7D-4946-8EF2-16E2C154A555}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{83B915D6-6A7D-4946-8EF2-16E2C154A555}.Debug|Any CPU.Build.0 = Debug|Any CPU
{83B915D6-6A7D-4946-8EF2-16E2C154A555}.Release|Any CPU.ActiveCfg = Release|Any CPU
{83B915D6-6A7D-4946-8EF2-16E2C154A555}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {B284F865-A51E-4E11-A5A0-A3D743E4F8E7}
EndGlobalSection
EndGlobal
20 changes: 12 additions & 8 deletions csharp/csharp.csproj → csharp/Euler.Test/Euler.Test.csproj
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<Project Sdk="Microsoft.NET.Sdk.Web">
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
Expand All @@ -7,21 +7,25 @@
<DockerDefaultTargetOS>Linux</DockerDefaultTargetOS>
<DockerfileContext>.</DockerfileContext>
<RestorePackagesWithLockFile>true</RestorePackagesWithLockFile>
<IsPackable>false</IsPackable>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.9.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.1.0" />
<PackageReference Include="Moq" Version="4.20.70" />
<PackageReference Include="xunit" Version="2.8.0" />
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="6.0.21" />
<PackageReference Include="Microsoft.EntityFrameworkCore.Design" Version="6.0.21">
<PrivateAssets>all</PrivateAssets>
<PackageReference Include="xunit" Version="2.4.1" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.3">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Microsoft.EntityFrameworkCore.Tools" Version="6.0.21">
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Include="coverlet.collector" Version="3.1.2">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\Euler\Euler.csproj" />
</ItemGroup>

</Project>
2 changes: 2 additions & 0 deletions csharp/Euler.Test/Usings.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
global using Euler;
global using Xunit;
Loading

0 comments on commit e721542

Please sign in to comment.