Skip to content

Commit d592cc4

Browse files
authored
Merge pull request #719 from stakx/net9.0
Add `net9.0` TFM
2 parents 115bd47 + a58da32 commit d592cc4

18 files changed

Lines changed: 3131 additions & 20 deletions

.gitignore

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ obj/
1212

1313
# Unit test scratch file (for DictionaryAdapter tests) and test runner results
1414
/out.xml
15-
/NetCoreClrTestResults.xml
15+
/Net*TestResults.xml
1616
/DesktopClrTestResults.xml
1717
/DesktopClrWeakNamedTestResults.xml
18-
/NetCoreClrWeakNamedTestResults.xml

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
## Next
44

55
Breaking Changes:
6-
- Updated target frameworks to .NET 8 (`net8.0`), .NET Standard 2.0 (`netstandard2.0`), and .NET Framework 4.6.2 (`net462`). Tests are being run on .NET 8, .NET 9, and on the .NET Framework. We no longer run tests on earlier frameworks nor on Mono. (@Romfos, #696)
6+
- Updated target frameworks to .NET 8 (`net8.0`), .NET 9 (`net9.0`), .NET Standard 2.0 (`netstandard2.0`), and .NET Framework 4.6.2 (`net462`). Tests are being run on .NET 8, .NET 9, and on the .NET Framework. We no longer run tests on earlier frameworks nor on Mono. (@Romfos, #696; @stakx, #719)
77
- Moved `Castle.Core.Logging.DiagnosticsLogger` into a separate NuGet package `Castle.Core-DiagnosticsLogger`, which renders the main package dependency-free for .NET 8+ (@snakefoot, #694)
88

99
Enhancements:

README.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Debugging symbols are available in symbol packages in the AppVeyor build artifac
1616

1717
## License
1818

19-
Castle Core is © 2004-2022 Castle Project. It is free software, and may be redistributed under the terms of the [Apache 2.0](http://opensource.org/licenses/Apache-2.0) license.
19+
Castle Core is © 2004-2025 Castle Project. It is free software, and may be redistributed under the terms of the [Apache 2.0](http://opensource.org/licenses/Apache-2.0) license.
2020

2121
## Contributing
2222

@@ -50,13 +50,13 @@ build.cmd
5050

5151
The following conditional compilation symbols (vertical) are currently defined for each of the build configurations (horizontal):
5252

53-
Symbol | .NET 4.6.2 | .NET Standard 2.0 | .NET 8
54-
----------------------------------- | ------------------ | ----------------- | ------------------
55-
`FEATURE_APPDOMAIN` | :white_check_mark: | :no_entry_sign: | :no_entry_sign:
56-
`FEATURE_ASSEMBLYBUILDER_SAVE` | :white_check_mark: | :no_entry_sign: | :no_entry_sign:
57-
`FEATURE_BYREFLIKE` | :no_entry_sign: | :no_entry_sign: | :white_check_mark:
58-
`FEATURE_SERIALIZATION` | :white_check_mark: | :no_entry_sign: | :no_entry_sign:
59-
`FEATURE_SYSTEM_CONFIGURATION` | :white_check_mark: | :no_entry_sign: | :no_entry_sign:
53+
Symbol | .NET 4.6.2 | .NET Standard 2.0 | .NET 8 | .NET 9
54+
----------------------------------- | ------------------ | ----------------- | ------------------ | ------------------
55+
`FEATURE_APPDOMAIN` | :white_check_mark: | :no_entry_sign: | :no_entry_sign: | :no_entry_sign:
56+
`FEATURE_ASSEMBLYBUILDER_SAVE` | :white_check_mark: | :no_entry_sign: | :no_entry_sign: | :no_entry_sign:
57+
`FEATURE_BYREFLIKE` | :no_entry_sign: | :no_entry_sign: | :white_check_mark: | :white_check_mark:
58+
`FEATURE_SERIALIZATION` | :white_check_mark: | :no_entry_sign: | :no_entry_sign: | :no_entry_sign:
59+
`FEATURE_SYSTEM_CONFIGURATION` | :white_check_mark: | :no_entry_sign: | :no_entry_sign: | :no_entry_sign:
6060

6161
* `FEATURE_APPDOMAIN` - enables support for features that make use of an AppDomain in the host.
6262
* `FEATURE_ASSEMBLYBUILDER_SAVE` - enabled support for saving the dynamically generated proxy assembly.

appveyor.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,8 @@ for:
6666
$wc = New-Object System.Net.WebClient
6767
$wc.UploadFile("https://ci.appveyor.com/api/testresults/nunit/$($env:APPVEYOR_JOB_ID)", (Resolve-Path "Net80TestResults.xml"))
6868
$wc.UploadFile("https://ci.appveyor.com/api/testresults/nunit/$($env:APPVEYOR_JOB_ID)", (Resolve-Path "Net80WeakNamedTestResults.xml"))
69+
$wc.UploadFile("https://ci.appveyor.com/api/testresults/nunit/$($env:APPVEYOR_JOB_ID)", (Resolve-Path "Net90TestResults.xml"))
70+
$wc.UploadFile("https://ci.appveyor.com/api/testresults/nunit/$($env:APPVEYOR_JOB_ID)", (Resolve-Path "Net90WeakNamedTestResults.xml"))
6971
$wc.UploadFile("https://ci.appveyor.com/api/testresults/nunit/$($env:APPVEYOR_JOB_ID)", (Resolve-Path "DesktopClrTestResults.xml"))
7072
$wc.UploadFile("https://ci.appveyor.com/api/testresults/nunit/$($env:APPVEYOR_JOB_ID)", (Resolve-Path "DesktopClrWeakNamedTestResults.xml"))
7173

build.sh

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22
# ****************************************************************************
3-
# Copyright 2004-2022 Castle Project - http://www.castleproject.org/
3+
# Copyright 2004-2025 Castle Project - http://www.castleproject.org/
44
# Licensed under the Apache License, Version 2.0 (the "License");
55
# you may not use this file except in compliance with the License.
66
# You may obtain a copy of the License at
@@ -43,3 +43,24 @@ then
4343
echo "Net8.0 Tests have failed, failing the build"
4444
exit 1
4545
fi
46+
47+
echo ---------------------------
48+
echo Running NET9.0 Tests
49+
echo ---------------------------
50+
51+
dotnet ./src/Castle.Core.Tests/bin/Release/net9.0/Castle.Core.Tests.dll --result=Net90TestResults.xml;format=nunit3
52+
dotnet ./src/Castle.Core.Tests.WeakNamed/bin/Release/net9.0/Castle.Core.Tests.WeakNamed.dll --result=Net90WeakNamedTestResults.xml;format=nunit3
53+
54+
# Ensure that all test runs produced a protocol file:
55+
if [[ !( -f Net90TestResults.xml &&
56+
-f Net90WeakNamedTestResults.xml ) ]]; then
57+
echo "Incomplete test results. Some test runs might not have terminated properly. Failing the build."
58+
exit 1
59+
fi
60+
61+
NET90_FAILCOUNT=$(grep -F "One or more child tests had errors" Net90TestResults.xml Net90WeakNamedTestResults.xml | wc -l)
62+
if [ $NET90_FAILCOUNT -ne 0 ]
63+
then
64+
echo "Net9.0 Tests have failed, failing the build"
65+
exit 1
66+
fi

buildscripts/build.cmd

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
@ECHO OFF
22
REM ****************************************************************************
3-
REM Copyright 2004-2022 Castle Project - http://www.castleproject.org/
3+
REM Copyright 2004-2025 Castle Project - http://www.castleproject.org/
44
REM Licensed under the Apache License, Version 2.0 (the "License");
55
REM you may not use this file except in compliance with the License.
66
REM You may obtain a copy of the License at
@@ -46,3 +46,10 @@ echo ---------------------------
4646

4747
dotnet .\src\Castle.Core.Tests\bin\%Configuration%\net8.0\Castle.Core.Tests.dll --result=Net80TestResults.xml;format=nunit3 || exit /b 1
4848
dotnet .\src\Castle.Core.Tests.WeakNamed\bin\%Configuration%\net8.0/Castle.Core.Tests.WeakNamed.dll --result=Net80WeakNamedTestResults.xml;format=nunit3 || exit /b 1
49+
50+
echo ---------------------------
51+
echo Running NET9.0 Tests
52+
echo ---------------------------
53+
54+
dotnet .\src\Castle.Core.Tests\bin\%Configuration%\net9.0\Castle.Core.Tests.dll --result=Net90TestResults.xml;format=nunit3 || exit /b 1
55+
dotnet .\src\Castle.Core.Tests.WeakNamed\bin\%Configuration%\net9.0/Castle.Core.Tests.WeakNamed.dll --result=Net90WeakNamedTestResults.xml;format=nunit3 || exit /b 1

0 commit comments

Comments
 (0)