Skip to content

Commit

Permalink
Moving to package framework net462 and test with net481
Browse files Browse the repository at this point in the history
  • Loading branch information
DanHarltey committed Nov 28, 2024
1 parent 3a6f248 commit 3fd56f2
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 11 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/main-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
os: [ubuntu-latest, windows-latest, macos-latest, buildjet-4vcpu-ubuntu-2204-arm]
env:
TEST_COVERAGE: ${{ matrix.os == 'ubuntu-latest' }}
NO_NET48: ${{ matrix.os == 'buildjet-4vcpu-ubuntu-2204-arm' }}
NO_NET481: ${{ matrix.os == 'buildjet-4vcpu-ubuntu-2204-arm' }}
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1
DOTNET_CLI_TELEMETRY_OPTOUT: 1
DOTNET_NOLOGO: true
Expand All @@ -32,9 +32,9 @@ jobs:
if [ "$TEST_COVERAGE" == "true" ]
then
./dotnet_build.sh test_coverage
elif [ "$NO_NET48" == "true" ]
elif [ "$NO_NET481" == "true" ]
then
./dotnet_build.sh no_net48
./dotnet_build.sh no_net481
else
./dotnet_build.sh
fi
Expand All @@ -56,7 +56,7 @@ jobs:
uses: coverallsapp/github-action@v2
with:
format: lcov
files: release/coverage.net9.info release/coverage.net48.info
files: release/coverage.net9.info release/coverage.net481.info

- name: Upload dotnet info
uses: actions/upload-artifact@v4
Expand Down
6 changes: 3 additions & 3 deletions scripts/dotnet_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ then
dotnet test ../ --configuration Release --no-build --verbosity normal --framework net9.0 --collect:"XPlat Code Coverage;Format=lcov"
find ../tests/Fastenshtein.Tests/TestResults/ -name "coverage.info" -type f -exec mv {} ../release/coverage.net9.info \;

dotnet test ../ --configuration Release --no-build --verbosity normal --framework net48 --collect:"XPlat Code Coverage;Format=lcov"
find ../tests/Fastenshtein.Tests/TestResults/ -name "coverage.info" -type f -exec mv {} ../release/coverage.net48.info \;
elif [ $1 = "no_net48" ]
dotnet test ../ --configuration Release --no-build --verbosity normal --framework net481 --collect:"XPlat Code Coverage;Format=lcov"
find ../tests/Fastenshtein.Tests/TestResults/ -name "coverage.info" -type f -exec mv {} ../release/coverage.net481.info \;
elif [ $1 = "no_net481" ]
then
dotnet test ../ --configuration Release --no-build --verbosity normal --framework net9.0
else
Expand Down
4 changes: 2 additions & 2 deletions scripts/github_release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ set -e
gh release create $1 \
"../release/Fastenshtein.nupkg" \
"../release/Fastenshtein.snupkg" \
"../release/coverage.net48.info#Code coverage report net48" \
"../release/coverage.net9.info#Code coverage report net8" \
"../release/coverage.net481.info#Code coverage report net481" \
"../release/coverage.net9.info#Code coverage report net9" \
"../release/dotnet_info.txt#Built with" \
--draft \
--generate-notes
2 changes: 1 addition & 1 deletion src/Fastenshtein/Fastenshtein.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>netstandard2.0;net452;net8.0;net9.0</TargetFrameworks>
<TargetFrameworks>netstandard2.0;net462;net8.0;net9.0</TargetFrameworks>
<GeneratePackageOnBuild>false</GeneratePackageOnBuild>
</PropertyGroup>

Expand Down
2 changes: 1 addition & 1 deletion tests/Fastenshtein.Tests/Fastenshtein.Tests.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net8.0;net9.0;net48</TargetFrameworks>
<TargetFrameworks>net8.0;net9.0;net481</TargetFrameworks>
<IsPackable>false</IsPackable>
</PropertyGroup>

Expand Down

0 comments on commit 3fd56f2

Please sign in to comment.