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

Updated test projects to .netcore 3.1 #2234

Closed
wants to merge 24 commits into from
Closed
Show file tree
Hide file tree
Changes from 8 commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
812113d
Updated test projects to .netcore 3.1
LaPeste Feb 8, 2021
7ddb0ab
Updated changelog
LaPeste Feb 8, 2021
f8af4fc
Updated Jenkins file
LaPeste Feb 8, 2021
742ead7
Updated MSBuild.Sdk.Extras
LaPeste Feb 8, 2021
c42d194
Reverted MSBuild.Sdk.Extras
LaPeste Feb 9, 2021
ae87a4d
Updated Jenkinsfile to fix linux
LaPeste Feb 9, 2021
b98d834
Cleaned up
LaPeste Feb 9, 2021
4053d00
Avoid Groovy to interpret the bash code as GString
LaPeste Feb 9, 2021
64fa1ca
Updated changelog
LaPeste Feb 10, 2021
f7a8e10
More changes to Jenkinsfile
LaPeste Feb 10, 2021
904186c
More changes to Jenkinsfile - again
LaPeste Feb 10, 2021
289845c
Jenkinsfile - better check for 3.1
LaPeste Feb 10, 2021
8a9e601
Attempt to create custom docker container
LaPeste Feb 10, 2021
b9d3e89
Dockerfile renamed
LaPeste Feb 11, 2021
afd0c3f
Changed comment on Jenkinsfile
LaPeste Feb 11, 2021
5605370
Remove nodefaultlib workaround that was used for server wrappers (#2241)
nirinchev Feb 10, 2021
adcdde2
Merge relevant portions from v10 and bump version to 10.5 (arbitraril…
nirinchev Feb 10, 2021
8fa868c
Enable LTO builds (#2239)
nirinchev Feb 11, 2021
c1b193e
Updated test projects to .netcore 3.1
LaPeste Feb 8, 2021
999ee2d
Updated changelog
LaPeste Feb 8, 2021
1a3b796
Updated changelog
LaPeste Feb 10, 2021
9774b02
Strange rebase behaviour needed a fix
LaPeste Feb 11, 2021
76d60e5
Unexplicable strange things happening with rebase needed a fix
LaPeste Feb 11, 2021
2237e13
Revert to "Changed comment on Jenkinsfile" given the huge mess of rebase
LaPeste Feb 11, 2021
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
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@

### Internal
* Using Core 10.3.3.
* Updated to dotnetcore 3.1.
Copy link
Member

Choose a reason for hiding this comment

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

This should say that only test projects were updated and also make a note that we're no longer testing .NET Core 2.0.


## 10.0.0-beta.6 (2021-01-25)

Expand Down
20 changes: 12 additions & 8 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -320,17 +320,17 @@ stage('Test') {
}
}
},
'.NET Core macOS': NetCoreTest('macos && dotnet', 'netcoreapp2.0'),
'.NET Core Linux': NetCoreTest('docker', 'netcoreapp2.0'),
'.NET Core Windows': NetCoreTest('windows && dotnet', 'netcoreapp2.0'),
'.NET Core macOS': NetCoreTest('macos && dotnet', 'netcoreapp3.1'),
'.NET Core Linux': NetCoreTest('docker', 'netcoreapp3.1'),
'.NET Core Windows': NetCoreTest('windows && dotnet', 'netcoreapp3.1'),
'.NET 5 macOS': NetCoreTest('macos && net5', 'net5.0'),
'.NET 5 Linux': NetCoreTest('docker', 'net5.0'),
'.NET 5 Windows': NetCoreTest('windows && dotnet', 'net5.0'),
'Weaver': {
rlmNode('dotnet && windows') {
unstash 'dotnet-source'
dir('Tests/Weaver/Realm.Fody.Tests') {
bat "dotnet run -f netcoreapp2.0 -c ${configuration} --result=TestResults.Weaver.xml --labels=After"
bat "dotnet run -f netcoreapp3.1 -c ${configuration} --result=TestResults.Weaver.xml --labels=After"
reportTests 'TestResults.Weaver.xml'
}
}
Expand Down Expand Up @@ -368,10 +368,14 @@ def NetCoreTest(String nodeName, String targetFramework) {

script += " --baasurl http://mongodb-realm:9090 --baasappid ${appId.trim()}"
// see https://stackoverflow.com/a/53782505
sh """
sh '''
# see https://github.com/dotnet/sdk/issues/11108
ABS_PATH_TO_FIX=/usr/share/dotnet/sdk/$(dotnet --version)/Sdks/Microsoft.NET.Sdk.WindowsDesktop/targets
mv $ABS_PATH_TO_FIX/Microsoft.WinFx.props Microsoft.WinFX.props && mv $ABS_PATH_TO_FIX/Microsoft.WinFx.targets Microsoft.WinFX.targets

export HOME=/tmp
${script}
"""
'''
}
}
} else {
Expand Down Expand Up @@ -448,8 +452,8 @@ boolean shouldPublishPackage() {
def String DetermineDockerImg(String targetFramework) {
String dockerImg = 'breakBuildIfNotSet'
switch(targetFramework) {
case 'netcoreapp2.0':
dockerImg = 'mcr.microsoft.com/dotnet/core/sdk:2.1'
case 'netcoreapp3.1':
dockerImg = 'mcr.microsoft.com/dotnet/sdk:3.1'
break
case 'net5.0':
dockerImg = 'mcr.microsoft.com/dotnet/sdk:5.0'
Expand Down
2 changes: 1 addition & 1 deletion Tests/Realm.Tests/Realm.Tests.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="MSBuild.Sdk.Extras">

<PropertyGroup>
<TargetFrameworks>net461;netcoreapp2.0;monoandroid90;xamarin.ios10;xamarin.mac20</TargetFrameworks>
<TargetFrameworks>net461;netcoreapp3.1;monoandroid90;xamarin.ios10;xamarin.mac20</TargetFrameworks>
<TargetFrameworks Condition="'$(OS)' == 'Windows_NT'">$(TargetFrameworks);uap10.0.18362</TargetFrameworks>
<TargetFrameworks Condition="'$(AddNet5Framework)' == 'true'">$(TargetFrameworks);net5.0</TargetFrameworks>
<RootNamespace>Realms.Tests</RootNamespace>
Expand Down
2 changes: 1 addition & 1 deletion Tests/Weaver/AssemblyToProcess/AssemblyToProcess.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net472;netcoreapp2.0</TargetFrameworks>
<TargetFrameworks>net472;netcoreapp3.1</TargetFrameworks>
</PropertyGroup>

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

<PropertyGroup>
<TargetFrameworks>net472;netcoreapp2.0</TargetFrameworks>
<TargetFrameworks>net472;netcoreapp3.1</TargetFrameworks>
<DisableFody>true</DisableFody>
<IsTestProject>true</IsTestProject>
<GenerateProgramFile>false</GenerateProgramFile>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net472;netcoreapp2.0</TargetFrameworks>
<TargetFrameworks>net472;netcoreapp3.1</TargetFrameworks>
</PropertyGroup>

</Project>