diff --git a/.github/workflows/dotnet-core.yml b/.github/workflows/dotnet-core.yml
index b6428a1..965cd35 100644
--- a/.github/workflows/dotnet-core.yml
+++ b/.github/workflows/dotnet-core.yml
@@ -23,7 +23,7 @@ jobs:
- name: Setup .NET Core
uses: actions/setup-dotnet@v4
with:
- dotnet-version: 6.0.x
+ dotnet-version: 8.0.x
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
diff --git a/Autodesk.Forge.sln b/Autodesk.Forge.sln
index 8a01a66..169019f 100644
--- a/Autodesk.Forge.sln
+++ b/Autodesk.Forge.sln
@@ -1,7 +1,7 @@
Microsoft Visual Studio Solution File, Format Version 12.00
-# Visual Studio 15
-VisualStudioVersion = 15.0.28307.106
+# Visual Studio Version 17
+VisualStudioVersion = 17.10.34928.147
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Autodesk.Forge.Core", "src\Autodesk.Forge.Core\Autodesk.Forge.Core.csproj", "{E59655EF-C1BF-4318-B344-B2C6B67E1A74}"
EndProject
diff --git a/CHANGELOG.md b/CHANGELOG.md
index f0f1543..2c4566d 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,7 @@
+### 4.0.0.0
+
+* Migrate to .Net 8
+
### 3.0.0.0
* Migrate to .Net 6
diff --git a/Directory.Build.props b/Directory.Build.props
index bb0658b..b6c4a44 100644
--- a/Directory.Build.props
+++ b/Directory.Build.props
@@ -1,6 +1,6 @@
- net6.0
+ net8.0
enable
\ No newline at end of file
diff --git a/Directory.Build.targets b/Directory.Build.targets
new file mode 100644
index 0000000..c1df222
--- /dev/null
+++ b/Directory.Build.targets
@@ -0,0 +1,2 @@
+
+
\ No newline at end of file
diff --git a/README.md b/README.md
index 73058e0..509e574 100644
--- a/README.md
+++ b/README.md
@@ -8,12 +8,12 @@
### Requirements
-- .NET 6 or later
+- .NET 8 or later
### Dependencies
-- [Newtonsoft.Json](https://github.com/JamesNK/Newtonsoft.Json) 13.0.1 or later
-- [Polly](https://github.com/App-vNext/Polly) 7.2.3 or later
+- [Newtonsoft.Json](https://github.com/JamesNK/Newtonsoft.Json)
+- [Polly](https://github.com/App-vNext/Polly)
### Changelog
diff --git a/src/Autodesk.Forge.Core.E2eTestHelpers/Autodesk.Forge.Core.E2eTestHelpers.csproj b/src/Autodesk.Forge.Core.E2eTestHelpers/Autodesk.Forge.Core.E2eTestHelpers.csproj
index fed8abb..ad01318 100644
--- a/src/Autodesk.Forge.Core.E2eTestHelpers/Autodesk.Forge.Core.E2eTestHelpers.csproj
+++ b/src/Autodesk.Forge.Core.E2eTestHelpers/Autodesk.Forge.Core.E2eTestHelpers.csproj
@@ -1,36 +1,21 @@
- true
- Autodesk Forge Team
- Autodesk
- Autodesk Forge
Shared code for Forge client sdks e2e tests
- Autodesk Inc.
- 3.0.1
- Apache-2.0
- https://github.com/Autodesk-Forge/forge-api-dotnet-core
- logo_forge-2-line.png
- For full release notes see https://github.com/Autodesk-Forge/forge-api-dotnet-core/blob/master/CHANGELOG.md
+ 4.0.0
+ false
+ NU5100
-
-
-
-
-
+
-
-
-
+
+
+
all
runtime; build; native; contentfiles; analyzers; buildtransitive
-
- false
-
-
diff --git a/src/Autodesk.Forge.Core/Autodesk.Forge.Core.csproj b/src/Autodesk.Forge.Core/Autodesk.Forge.Core.csproj
index dffd8f6..e893aa4 100644
--- a/src/Autodesk.Forge.Core/Autodesk.Forge.Core.csproj
+++ b/src/Autodesk.Forge.Core/Autodesk.Forge.Core.csproj
@@ -1,37 +1,19 @@
-
+
- true
- Autodesk Forge
- Autodesk Forge
- Autodesk
- Autodesk Forge
- Shared code for Forge client sdks
- Autodesk Inc.
- 3.0.2
- 3.0.2.0
- 3.0.2.0
- Autodesk.Forge.Core
- Apache-2.0
- https://github.com/Autodesk-Forge/forge-api-dotnet-core
- logo_forge-2-line.png
- For full release notes see https://github.com/Autodesk-Forge/forge-api-dotnet-core/blob/master/CHANGELOG.md
+ Shared code for APS client sdks
+ 4.0.0
-
-
-
-
-
-
-
+
+
+
-
+
-
diff --git a/src/Directory.Build.props b/src/Directory.Build.props
new file mode 100644
index 0000000..141d217
--- /dev/null
+++ b/src/Directory.Build.props
@@ -0,0 +1,20 @@
+
+
+
+ true
+ Autodesk
+ Autodesk Inc.
+ Apache-2.0
+ https://github.com/Autodesk-Forge/forge-api-dotnet-core
+ logo_forge-2-line.png
+ For full release notes see https://github.com/Autodesk-Forge/forge-api-dotnet-core/blob/master/CHANGELOG.md
+ README.md
+ true
+ true
+ snupkg
+
+
+
+
+
+
\ No newline at end of file
diff --git a/nuget.targets b/src/Directory.Build.targets
similarity index 80%
rename from nuget.targets
rename to src/Directory.Build.targets
index 5e29d00..939344e 100644
--- a/nuget.targets
+++ b/src/Directory.Build.targets
@@ -1,10 +1,11 @@
-
+
+
-
diff --git a/tests/Autodesk.Forge.Core.Test/Autodesk.Forge.Core.Test.csproj b/tests/Autodesk.Forge.Core.Test/Autodesk.Forge.Core.Test.csproj
index c960762..ce9bd34 100644
--- a/tests/Autodesk.Forge.Core.Test/Autodesk.Forge.Core.Test.csproj
+++ b/tests/Autodesk.Forge.Core.Test/Autodesk.Forge.Core.Test.csproj
@@ -5,10 +5,10 @@
-
+
-
-
+
+
all
runtime; build; native; contentfiles; analyzers; buildtransitive
diff --git a/tests/Autodesk.Forge.Core.Test/TestForgeAgentHandler.cs b/tests/Autodesk.Forge.Core.Test/TestForgeAgentHandler.cs
index f1ff57e..9419a9e 100644
--- a/tests/Autodesk.Forge.Core.Test/TestForgeAgentHandler.cs
+++ b/tests/Autodesk.Forge.Core.Test/TestForgeAgentHandler.cs
@@ -12,7 +12,7 @@ namespace Autodesk.Forge.Core.Test
public class TestForgeAgentHandler
{
[Fact]
- public async void TestUser()
+ public async Task TestUser()
{
var json = @"
{
diff --git a/tests/Autodesk.Forge.Core.Test/TestForgeHandler.cs b/tests/Autodesk.Forge.Core.Test/TestForgeHandler.cs
index 11ffb35..0ca77c2 100644
--- a/tests/Autodesk.Forge.Core.Test/TestForgeHandler.cs
+++ b/tests/Autodesk.Forge.Core.Test/TestForgeHandler.cs
@@ -37,14 +37,14 @@ public void TestNullConfigurationThrows()
}
[Fact]
- public async void TestNoRequestUriThrows()
+ public async Task TestNoRequestUriThrows()
{
var fh = new HttpMessageInvoker(new ForgeHandler(Options.Create(new ForgeConfiguration())));
await Assert.ThrowsAsync($"{nameof(HttpRequestMessage)}.{nameof(HttpRequestMessage.RequestUri)}", () => fh.SendAsync(new HttpRequestMessage(), CancellationToken.None));
}
[Fact]
- public async void TestNoClientIdThrows()
+ public async Task TestNoClientIdThrows()
{
var fh = new HttpMessageInvoker(new ForgeHandler(Options.Create(new ForgeConfiguration())));
var req = new HttpRequestMessage();
@@ -54,7 +54,7 @@ public async void TestNoClientIdThrows()
}
[Fact]
- public async void TestNoClientSecretThrows()
+ public async Task TestNoClientSecretThrows()
{
var fh = new HttpMessageInvoker(new ForgeHandler(Options.Create(new ForgeConfiguration() { ClientId = "ClientId" })));
var req = new HttpRequestMessage();
@@ -64,7 +64,7 @@ public async void TestNoClientSecretThrows()
}
[Fact]
- public async void TestFirstCallAuthenticates()
+ public async Task TestFirstCallAuthenticates()
{
var sink = new Mock(MockBehavior.Strict);
sink.Protected().As().SetupSequence(o => o.SendAsync(It.IsAny(), It.IsAny()))
@@ -97,7 +97,7 @@ public async void TestFirstCallAuthenticates()
}
[Fact]
- public async void TestFirstCallAuthenticatesNonDefaultUser()
+ public async Task TestFirstCallAuthenticatesNonDefaultUser()
{
var req = new HttpRequestMessage();
var config = new ForgeConfiguration()
@@ -153,7 +153,7 @@ public async void TestFirstCallAuthenticatesNonDefaultUser()
}
[Fact]
- public async void TestRetryOnceOnAuthenticationFailure()
+ public async Task TestRetryOnceOnAuthenticationFailure()
{
var newToken = "newToken";
var cachedToken = "cachedToken";
@@ -202,7 +202,7 @@ public async void TestRetryOnceOnAuthenticationFailure()
}
[Fact]
- public async void TestRefreshExpiredToken()
+ public async Task TestRefreshExpiredToken()
{
var newToken = "newToken";
var cachedToken = "cachedToken";
@@ -245,7 +245,7 @@ public async void TestRefreshExpiredToken()
}
[Fact]
- public async void TestRefreshExpiredTokenByOneThreadOnly()
+ public async Task TestRefreshExpiredTokenByOneThreadOnly()
{
var newToken = "newToken";
var cachedToken = "cachedToken";
@@ -300,7 +300,7 @@ public async void TestRefreshExpiredTokenByOneThreadOnly()
}
[Fact]
- public async void TestUseGoodToken()
+ public async Task TestUseGoodToken()
{
var cachedToken = "cachedToken";
var req = new HttpRequestMessage();
@@ -339,7 +339,7 @@ public async void TestUseGoodToken()
}
[Fact]
- public async void TestNoRefreshOnClientProvidedToken()
+ public async Task TestNoRefreshOnClientProvidedToken()
{
var token = "blabla";
var req = new HttpRequestMessage();
@@ -382,7 +382,7 @@ public async void TestNoRefreshOnClientProvidedToken()
public class TestForgeHandler2
{
[Fact]
- public async void TestCorrectNumberOfRetries()
+ public async Task TestCorrectNumberOfRetries()
{
var cachedToken = "cachedToken";
var req = new HttpRequestMessage();
@@ -431,7 +431,7 @@ public async void TestCorrectNumberOfRetries()
public class TestForgeHandler3
{
[Fact]
- public async void TestTimeout()
+ public async Task TestTimeout()
{
var cachedToken = "cachedToken";
var req = new HttpRequestMessage();
@@ -470,7 +470,7 @@ public async void TestTimeout()
public class TestForgeHandler4
{
[Fact]
- public async void TestCircuitBreaker()
+ public async Task TestCircuitBreaker()
{
var cachedToken = "cachedToken";
var req = new HttpRequestMessage();
@@ -529,7 +529,7 @@ public class TestCustomTimeout
};
[Fact]
- public async void TestTriggeredTimeout()
+ public async Task TestTriggeredTimeout()
{
var (sink, requestSender) = GetReady(1, TimeSpan.FromMilliseconds(1100));
await Assert.ThrowsAsync(async () => await requestSender());
@@ -538,7 +538,7 @@ public async void TestTriggeredTimeout()
}
[Fact]
- public async void TestNoTimeout()
+ public async Task TestNoTimeout()
{
var (sink, requestSender) = GetReady(1, TimeSpan.FromMilliseconds(100));
diff --git a/tests/Autodesk.Forge.Core.Test/TestMarshalling.cs b/tests/Autodesk.Forge.Core.Test/TestMarshalling.cs
index 0168e49..1c206c1 100644
--- a/tests/Autodesk.Forge.Core.Test/TestMarshalling.cs
+++ b/tests/Autodesk.Forge.Core.Test/TestMarshalling.cs
@@ -6,33 +6,33 @@ namespace Autodesk.Forge.Core.Test
public class TestMarshalling
{
[Fact]
- public async void TestDeserializeThrowsOnNull()
+ public async Task TestDeserializeThrowsOnNull()
{
await Assert.ThrowsAsync(() => Marshalling.DeserializeAsync(null));
}
[Fact]
- public async void TestDeserializeNonJsonThrows()
+ public async Task TestDeserializeNonJsonThrows()
{
await Assert.ThrowsAsync(() => Marshalling.DeserializeAsync(new ByteArrayContent(new byte[] { 0, 2, 3 })));
}
[Fact]
- public async void TestDeserializeValidString()
+ public async Task TestDeserializeValidString()
{
var ret = await Marshalling.DeserializeAsync(new StringContent("\"bla\"", Encoding.UTF8, "application/json"));
Assert.Equal("bla", ret);
}
[Fact]
- public async void TestDeserializeNull()
+ public async Task TestDeserializeNull()
{
var ret = await Marshalling.DeserializeAsync(new StringContent("null", Encoding.UTF8, "application/json"));
Assert.Null(ret);
}
[Fact]
- public async void TestDeserializeNullInvalid()
+ public async Task TestDeserializeNullInvalid()
{
await Assert.ThrowsAsync (() => Marshalling.DeserializeAsync(new StringContent("null", Encoding.UTF8, "application/json")));
}