Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade dotnet 8 #103

Closed
wants to merge 29 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
599462e
move WeSay.sln into repo root
hahn-kev Feb 23, 2024
1bfa073
upgrade wesay to dotnet 8
hahn-kev Feb 27, 2024
283cece
get weSay working with dotnet 8
hahn-kev Feb 27, 2024
26e7605
compile ui tests
hahn-kev Apr 5, 2024
b5b4e12
get tests passing and compiling
hahn-kev Apr 5, 2024
b3ced83
get most tests running for WeSay.Project.Tests.csproj
hahn-kev Apr 5, 2024
7c37cd2
build and run LexicalModel.Tests.csproj
hahn-kev Apr 5, 2024
965b17f
build and run LexicalTools.Tests.csproj
hahn-kev Apr 5, 2024
5e1a48d
build and run WeSay.ConfigTool.Tests.csproj
hahn-kev Apr 5, 2024
4cf7e39
build and test Addin.Transform.Tests.csproj
hahn-kev Apr 5, 2024
33ab301
build Addin.Backup.Tests.csproj
hahn-kev Apr 5, 2024
0234625
build LifWord2Json
hahn-kev Apr 5, 2024
3b3ff06
build WeSay.App.Tests.csproj
hahn-kev Apr 5, 2024
575b1b4
update sil core desktop to new version which includes UsbDrive stuff
hahn-kev Apr 15, 2024
623ebeb
cleanup sldr once in fixture teardown
hahn-kev Apr 15, 2024
5984d82
update workflow and WeSay.proj file to point to updated sln location
hahn-kev Apr 16, 2024
6fee149
install dotnet 8 instead of 5
hahn-kev Apr 16, 2024
7d37ba8
use latest windows
hahn-kev Apr 16, 2024
5fbc075
include mono workaround for net5+, use FileHelper as Grep replacement
hahn-kev Apr 16, 2024
0fb8193
add Nunit3 Test adapter
hahn-kev Apr 16, 2024
8fcf42b
add github action logger for tests
hahn-kev Apr 16, 2024
8e028e4
add space after -- for run config
hahn-kev Apr 16, 2024
e5af3b4
allow not calling dispose on ProjectDirectorySetupForTesting
hahn-kev Apr 16, 2024
5621c82
Removed net8.0-windows from OutputPath
josephmyers Jul 11, 2024
09c0401
change how we detect an unknown locale to use the CultureTypes property
hahn-kev Jul 11, 2024
d33293a
set maxcpucount=1 when running tests to avoid concurrency issues
hahn-kev Jul 11, 2024
430ccd7
Reinstated test skipping for build server
josephmyers Jul 12, 2024
71b1a8f
Skip a few extra tests
josephmyers Jul 12, 2024
06bc0d6
Cleaup
josephmyers Jul 12, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 6 additions & 8 deletions .github/workflows/Installer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
strategy:
fail-fast: true
matrix:
os: [windows-2019]
os: [windows-latest]
runs-on: ${{ matrix.os }}

steps:
Expand All @@ -21,18 +21,16 @@ jobs:
submodules: recursive
fetch-depth: 0

# Install the .NET Core workload
- name: Install .NET Core
uses: actions/setup-dotnet@v1
- name: Install .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 5.0.x
dotnet-version: 8.0.x

# Add MSBuild to the PATH: https://github.com/microsoft/setup-msbuild
- name: Setup MSBuild.exe (Windows OS)
uses: microsoft/setup-msbuild@v1.0.2
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: true # So the PATH can be set by this step
if: ${{ matrix.os == 'windows-2019' }}

# Run the unit tests
- name: Restore
Expand All @@ -42,10 +40,10 @@ jobs:
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: true # So gitversion can set environment vars during the build
run: msbuild src/WeSay.sln /p:Configuration=Release

- name: Build Installer
run: msbuild build/Installer.targets /p:Configuration=Release /p:Platform=x86 /t:BuildRelease

- name: Publish Installer
uses: actions/upload-artifact@v2
with:
Expand Down
42 changes: 9 additions & 33 deletions .github/workflows/PR.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,50 +11,26 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [windows-2019]
os: [windows-latest]
runs-on: ${{ matrix.os }}

steps:
- name: Checkout
uses: actions/checkout@v2.3.4
uses: actions/checkout@v4
with:
fetch-depth: 0

# Install the .NET Core workload
- name: Install .NET Core
uses: actions/setup-dotnet@v1
- name: Install .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 5.0.x
dotnet-version: 8.0.x

# Add MSBuild to the PATH: https://github.com/microsoft/setup-msbuild
- name: Setup MSBuild.exe (Windows OS)
uses: microsoft/setup-msbuild@v1.0.2
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: true # So the PATH can be set by this step
if: ${{ matrix.os == 'windows-2019' }}

# Run the unit tests
- name: Restore
run: nuget restore src/WeSay.sln
run: dotnet restore

- name: Build
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: true # So gitversion can set environment vars during the build
run: msbuild src/WeSay.sln
run: dotnet build

- name: Prepare to Test
run: msbuild build/WeSay.proj /t:RestoreBuildTasks

- name: Test
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: true # So testing files and folders can be created
run: msbuild build/WeSay.proj /t:TestOnly /p:Configuration=Debug /p:Platform="x86" /p:CI=true /v:diag

- name: Test Report
uses: jasonleenaylor/nunit-reporter@63ab85dd5da111c3f4ef95f2fb73bbe667f58db9
if: always()
with:
path: output/**/TestResults.xml
access-token: ${{ secrets.GITHUB_TOKEN }}
reportTitle: "Test Results (${{ matrix.os }})"
numFailures:
# space after -- before RunConfig is required
run: dotnet test --filter "TestCategory != SkipOnCI" --no-build -maxcpucount:1 --logger "GitHubActions;summary.includePassedTests=true;summary.includeSkippedTests=true" -- RunConfiguration.CollectSourceInformation=true
1 change: 1 addition & 0 deletions Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<Project>
<PropertyGroup>
<Mercurial4ChorusDestDir>$(MSBuildThisFileDirectory)</Mercurial4ChorusDestDir>
<AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
</PropertyGroup>
</Project>
348 changes: 175 additions & 173 deletions src/WeSay.sln → WeSay.sln

Large diffs are not rendered by default.

10 changes: 5 additions & 5 deletions build/WeSay.proj
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<SolutionPath>$(RootDir)/$(Solution)</SolutionPath>
<Configuration Condition="'$(Configuration)'==''">Debug</Configuration>
<LinuxExcludeCategories Condition="'$(OS)'!='Windows_NT'">KnownMonoIssue,</LinuxExcludeCategories>
<ExtraExcludeCategories Condition="'$(teamcity_version)' != '' Or '$(JENKINS_URL)' != '' Or '$(CI)' != ''">SkipOnTeamCity,$(LinuxExcludeCategories)</ExtraExcludeCategories>
<ExtraExcludeCategories Condition="'$(teamcity_version)' != '' Or '$(JENKINS_URL)' != '' Or '$(CI)' != ''">SkipOnCI,$(LinuxExcludeCategories)</ExtraExcludeCategories>
<useNUnit-x86 Condition="'$(OS)'=='Windows_NT'">true</useNUnit-x86>
<Platform Condition="'$(Platform)'==''">x</Platform>
<useNUnit-x86 Condition="'$(OS)'!='Windows_NT'">false</useNUnit-x86>
Expand Down Expand Up @@ -46,7 +46,7 @@
]]></Code>
</Task>
</UsingTask>

<Import Project="NuGet.targets"/>

<Target Name="RestoreBuildTasks" DependsOnTargets="CheckPrerequisites">
Expand All @@ -66,10 +66,10 @@
</ItemGroup>

<Target Name="Build">
<MSBuild Projects="$(RootDir)/src/WeSay.sln"
<MSBuild Projects="$(RootDir)/WeSay.sln"
Properties="Configuration=$(Configuration);RootDir=$(RootDir);Platform=$(Platform)" />
</Target>

<Target Name="Test" DependsOnTargets="Build">
<CallTarget Targets="TestOnly" Condition="!$(RestartBuild)" />
<MSBuild Projects="$(MSBuildProjectFullPath)" Targets="TestOnly"
Expand All @@ -86,7 +86,7 @@
<Output PropertyName="ExcludeArgument" TaskParameter="ExcludeArg" />
</BuildExcludeString>
<Message Text="Exclude Arg = $(ExcludeArgument)" />
<Exec Command="$(RootDir)/packages/NUnit.ConsoleRunner/tools/nunit3-console @(TestAssemblies->'%(Filename)%(Extension)', ' ') &quot;--result:$(RootDir)/output/$(Configuration)/TestResults.xml;format=nunit3&quot; --labels=Before --x86 --agents=1 $(ExcludeArgument)"
<Exec Command="$(RootDir)/packages/NUnit.ConsoleRunner/tools/nunit3-console @(TestAssemblies->'%(Filename)%(Extension)', ' ') &quot;--result:$(RootDir)/output/$(Configuration)/TestResults.xml;format=nunit3&quot; --labels=Before --x86 --agents=1 $(ExcludeArgument)"
WorkingDirectory="$(RootDir)/output/$(Configuration)" />
</Target>
</Project>
2 changes: 1 addition & 1 deletion build/build.common.proj
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<PropertyGroup>
<useNUnit-x86 Condition="'$(OS)'=='Windows_NT'">true</useNUnit-x86>
<useNUnit-x86 Condition="'$(OS)'!='Windows_NT'">false</useNUnit-x86>
<ExtraExcludeCategories Condition="'$(teamcity_version)' != ''">SkipOnTeamCity,$(ExtraExcludeCategories)</ExtraExcludeCategories>
<ExtraExcludeCategories Condition="'$(teamcity_version)' != ''">SkipOnCI,$(ExtraExcludeCategories)</ExtraExcludeCategories>
</PropertyGroup>

<PropertyGroup>
Expand Down
2 changes: 1 addition & 1 deletion build/build.mono.proj
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

perhaps in a separate PR, we can remove all mono-specific references, like this file

Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
Targets="Build"
Properties="Configuration=$(Configuration);Constants=$(Constants)" />
<Exec Condition="'$(action)' == 'test'"
Command="$(MONO_PREFIX)/bin/mono --debug $(MONO_PREFIX)/lib/mono/4.0/nunit-console.exe -noshadow -exclude=SkipOnTeamCity [!P]*.Tests.dll -xml=WeSay.nunit-output.xml"
Command="$(MONO_PREFIX)/bin/mono --debug $(MONO_PREFIX)/lib/mono/4.0/nunit-console.exe -noshadow -exclude=SkipOnCI [!P]*.Tests.dll -xml=WeSay.nunit-output.xml"
WorkingDirectory="$(RootDir)/output/$(Configuration)"
Timeout="4500000"/>
</Target>
Expand Down
6 changes: 0 additions & 6 deletions src/.nuget/packages.config

This file was deleted.

Loading
Loading