Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
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
15 changes: 8 additions & 7 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,22 +16,23 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v5
with:
fetch-depth: 0
filter: tree:0
- name: Setup .NET 10.0
uses: actions/setup-dotnet@v5
with:
dotnet-version: 10.0.x
dotnet-quality: 'preview'
- name: Setup .NET 9.0
uses: actions/setup-dotnet@v2
uses: actions/setup-dotnet@v5
with:
dotnet-version: 9.0.x
- name: Setup .NET 8.0
uses: actions/setup-dotnet@v2
uses: actions/setup-dotnet@v5
with:
dotnet-version: 8.0.x
- name: Setup .NET 6.0
uses: actions/setup-dotnet@v2
with:
dotnet-version: 6.0.x
- name: Restore tools
run: dotnet tool restore
- name: Run the build script
Expand Down
15 changes: 8 additions & 7 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,22 +22,23 @@ jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v5
with:
fetch-depth: 0
filter: tree:0
- name: Setup .NET 10.0
uses: actions/setup-dotnet@v5
with:
dotnet-version: 10.0.x
dotnet-quality: 'preview'
- name: Setup .NET 9.0
uses: actions/setup-dotnet@v2
uses: actions/setup-dotnet@v5
with:
dotnet-version: 9.0.x
- name: Setup .NET 8.0
uses: actions/setup-dotnet@v2
uses: actions/setup-dotnet@v5
with:
dotnet-version: 8.0.x
- name: Setup .NET 6.0
uses: actions/setup-dotnet@v2
with:
dotnet-version: 6.0.x
- name: Restore tools
run: dotnet tool restore
- name: Run the build script
Expand Down
1 change: 1 addition & 0 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ Each API area is encapsulated in its own module:
- **Request Signing**: Cryptographic signing using EC512 keys via TrueLayer.Signing package
- **Polymorphic Serialization**: OneOf types for discriminated unions, custom JSON converters
### Target Frameworks
- .NET 10.0
- .NET 9.0
- .NET 8.0
- .NET Standard 2.1
Expand Down
2 changes: 1 addition & 1 deletion build.cake
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// Install .NET Core Global tools.
#tool "dotnet:?package=dotnet-reportgenerator-globaltool&version=5.4.9"
#tool "dotnet:?package=dotnet-reportgenerator-globaltool&version=5.4.13"
#tool "dotnet:?package=coveralls.net&version=4.0.1"

// Install addins
Expand Down
2 changes: 1 addition & 1 deletion examples/MvcExample/MvcExample.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk.Web">

<PropertyGroup>
<TargetFramework>net9.0</TargetFramework>
<TargetFramework>net10.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion global.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"sdk": {
"version": "9.0.100",
"version": "10.0.100-rc.1.25451.107",
"rollForward": "latestMinor"
}
}
6 changes: 3 additions & 3 deletions src/TrueLayer/ApiClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
using System.Text.Json;
using TrueLayer.Caching;
using TrueLayer.Signing;
#if NET6_0 || NET6_0_OR_GREATER
#if NET8_0 || NET8_0_OR_GREATER
using System.Net.Http.Json;
#endif

Expand Down Expand Up @@ -176,7 +176,7 @@ private async Task<TData> DeserializeJsonAsync<TData>(HttpResponseMessage httpRe
{
try
{
#if NET6_0 || NET6_0_OR_GREATER
#if NET8_0 || NET8_0_OR_GREATER
data = await httpResponse.Content.ReadFromJsonAsync<TData>(SerializerOptions.Default, cancellationToken);
#else
using var contentStream = await httpResponse.Content.ReadAsStreamAsync();
Expand Down Expand Up @@ -230,7 +230,7 @@ private Task<HttpResponseMessage> SendJsonRequestAsync(
}
else if (request is { }) // Otherwise we can serialize directly to stream for .NET 5.0 onwards
{
#if (NET6_0 || NET6_0_OR_GREATER)
#if (NET8_0 || NET8_0_OR_GREATER)
httpContent = JsonContent.Create(request, request.GetType(), options: SerializerOptions.Default);
#else
// for older versions of .NET we'll have to fall back to using StringContent
Expand Down
2 changes: 1 addition & 1 deletion src/TrueLayer/ApiResponseOfT.cs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public ApiResponse(TData data, HttpStatusCode statusCode, string? traceId)
/// Gets whether the API request completed successfully
/// </summary>
/// <returns>True if successful, otherwise False</returns>
#if NET6_0 || NET6_0_OR_GREATER
#if NET8_0 || NET8_0_OR_GREATER
[MemberNotNullWhen(true, nameof(Data))]
#endif
public override bool IsSuccessful => base.IsSuccessful;
Expand Down
2 changes: 1 addition & 1 deletion src/TrueLayer/SigningKey.cs
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ private static ECDsa CreateECDsaKey(string privateKey)

var key = ECDsa.Create();

#if (NET6_0 || NET6_0_OR_GREATER)
#if (NET8_0 || NET8_0_OR_GREATER)
// Ref https://www.scottbrady91.com/C-Sharp/PEM-Loading-in-dotnet-core-and-dotnet
key.ImportFromPem(privateKey);
#else
Expand Down
4 changes: 2 additions & 2 deletions src/TrueLayer/TrueLayer.csproj
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>net9.0;net8.0;netstandard2.1</TargetFrameworks>
<TargetFrameworks>net10.0;net9.0;net8.0;netstandard2.1</TargetFrameworks>
<RootNamespace>TrueLayer</RootNamespace>
<AssemblyName>TrueLayer.Client</AssemblyName>
<PackageId>TrueLayer.Client</PackageId>
<Description>.NET client for the TrueLayer API</Description>
<PackageIcon>icon.png</PackageIcon>
<LangVersion>10.0</LangVersion>
<LangVersion>12.0</LangVersion>
<Authors>TrueLayer</Authors>
<Company>TrueLayer</Company>
<RepositoryUrl>https://github.com/TrueLayer/truelayer-dotnet</RepositoryUrl>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net9.0</TargetFramework>
<TargetFramework>net10.0</TargetFramework>
<IsPackable>false</IsPackable>
<RootNamespace>TrueLayer.AcceptanceTests</RootNamespace>
<AssemblyName>TrueLayer.AcceptanceTests</AssemblyName>
<Nullable>enable</Nullable>
<WarningsAsErrors>nullable;</WarningsAsErrors>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="FluentAssertions" Version="7.0.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.12.0" />
<PackageReference Include="xunit" Version="2.9.2" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.8.2">
<PackageReference Include="FluentAssertions" Version="7.2.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.14.1" />
<PackageReference Include="xunit" Version="2.9.3" />
<PackageReference Include="xunit.runner.visualstudio" Version="3.1.4">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Include="coverlet.msbuild" Version="6.0.2">
<PackageReference Include="coverlet.msbuild" Version="6.0.4">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
Expand Down
4 changes: 2 additions & 2 deletions test/TrueLayer.Benchmarks/TrueLayer.Benchmarks.csproj
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net9.0</TargetFramework>
<TargetFramework>net10.0</TargetFramework>
<Nullable>enable</Nullable>
<WarningsAsErrors>nullable;</WarningsAsErrors>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="BenchmarkDotNet" Version="0.14.0" />
<PackageReference Include="BenchmarkDotNet" Version="0.15.2" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\src\TrueLayer\TrueLayer.csproj"/>
Expand Down
14 changes: 7 additions & 7 deletions test/TrueLayer.Tests/TrueLayer.Tests.csproj
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>net9.0;net8.0;net6.0</TargetFrameworks>
<TargetFrameworks>net10.0;net9.0;net8.0</TargetFrameworks>
<IsPackable>false</IsPackable>
<LangVersion>10.0</LangVersion>
<LangVersion>12.0</LangVersion>
<Nullable>enable</Nullable>
<WarningsAsErrors>nullable;</WarningsAsErrors>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.12.0"/>
<PackageReference Include="xunit" Version="2.9.2"/>
<PackageReference Include="xunit.runner.visualstudio" Version="2.8.2">
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.14.1" />
<PackageReference Include="xunit" Version="2.9.3" />
<PackageReference Include="xunit.runner.visualstudio" Version="3.1.4">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="coverlet.msbuild" Version="6.0.2">
<PackageReference Include="coverlet.msbuild" Version="6.0.4">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="FluentAssertions" Version="7.0.0" />
<PackageReference Include="FluentAssertions" Version="7.2.0" />
<PackageReference Include="RichardSzalay.MockHttp" Version="7.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration" Version="9.0.0" />
</ItemGroup>
Expand Down
Loading