Skip to content

Commit 390de5b

Browse files
eustascopybara-github
authored andcommitted
build and test csharp decoder
PiperOrigin-RevId: 822490991
1 parent 3499acb commit 390de5b

3 files changed

Lines changed: 51 additions & 0 deletions

File tree

.github/workflows/build_test.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -355,3 +355,21 @@ jobs:
355355
python2.7 -VV
356356
python2.7 -c "import sys; sys.exit('Invalid python version') if '.'.join(map(str,sys.version_info[0:2])) != '2.7' else True"
357357
python2.7 setup.py test
358+
359+
build_test_dotnet:
360+
name: Build and test with .NET
361+
runs-on: ubuntu-latest
362+
steps:
363+
364+
- name: Checkout the source
365+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
366+
with:
367+
submodules: false
368+
fetch-depth: 1
369+
370+
- name: Build / Test
371+
run: |
372+
cd csharp
373+
dotnet build brotlidec.csproj --configuration Release
374+
dotnet test brotlidec.Tests.csproj
375+

csharp/brotlidec.Tests.csproj

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<Project Sdk="Microsoft.NET.Sdk">
2+
3+
<PropertyGroup>
4+
<TargetFramework>net9.0</TargetFramework>
5+
<EnableDefaultCompileItems>false</EnableDefaultCompileItems>
6+
</PropertyGroup>
7+
8+
<ItemGroup>
9+
<!-- Both regular sources and test sources -->
10+
<Compile Include="org\brotli\dec\*.cs" />
11+
</ItemGroup>
12+
13+
<ItemGroup>
14+
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="18.0.0" />
15+
<!-- Stick to NUnit3 until tests are regenerated -->
16+
<PackageReference Include="NUnit" Version="3.14.0" />
17+
<PackageReference Include="NUnit3TestAdapter" Version="5.2.0" />
18+
</ItemGroup>
19+
20+
</Project>

csharp/brotlidec.csproj

Lines changed: 13 additions & 0 deletions
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+
<EnableDefaultCompileItems>false</EnableDefaultCompileItems>
6+
</PropertyGroup>
7+
8+
<ItemGroup>
9+
<Compile Include="org\brotli\dec\*.cs" />
10+
<Compile Remove="**\*Test.cs" />
11+
</ItemGroup>
12+
13+
</Project>

0 commit comments

Comments
 (0)