diff --git a/.github/workflows/generate-client.yml b/.github/workflows/generate-client.yml index db0b392..e9577b9 100644 --- a/.github/workflows/generate-client.yml +++ b/.github/workflows/generate-client.yml @@ -15,10 +15,10 @@ jobs: runs-on: ubuntu-latest timeout-minutes: 10 steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup Node.js environment - uses: actions/setup-node@v2.5.1 + uses: actions/setup-node@v4 with: node-version: "16" @@ -48,7 +48,7 @@ jobs: private_key: ${{ secrets.LF_PULL_REQUEST_BOT_PRIVATE_KEY }} - name: Create pull request - uses: peter-evans/create-pull-request@v4.2.3 + uses: peter-evans/create-pull-request@v4 with: token: ${{ steps.generate-token.outputs.token }} branch: ${{ github.ref_name }}-generate-${{ env.API_VERSION }}-client diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index d762983..2b0af1c 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -12,7 +12,7 @@ on: env: API_VERSION: 'v2' - VERSION_PREFIX: '1.0.1' + VERSION_PREFIX: '1.0.2' GITHUB_PAGES_BRANCH: 'gh-pages' jobs: @@ -20,14 +20,12 @@ jobs: runs-on: ubuntu-latest timeout-minutes: 30 steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup .NET - uses: actions/setup-dotnet@v2 + uses: actions/setup-dotnet@v4 with: - dotnet-version: | - 3.1.x - 6.0.x + dotnet-version: 8.0.x - name: Restore dependencies run: dotnet restore @@ -64,7 +62,7 @@ jobs: timeout-minutes: 10 needs: [ build-n-test ] # wait for build to finish steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Install dependencies run: | @@ -90,7 +88,7 @@ jobs: run: doxygen ./doxygen/doxygen.conf - name: Upload a build artifact - uses: actions/upload-artifact@v3.1.0 + uses: actions/upload-artifact@v4 with: name: documentation-artifact path: ${{ github.workspace }}/generated_documentation/html @@ -106,12 +104,12 @@ jobs: if: ${{ github.run_attempt != 1 }} needs: [ build-n-test, build-documentation ] # wait for build to finish steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup .NET - uses: actions/setup-dotnet@v2 + uses: actions/setup-dotnet@v4 with: - dotnet-version: 6.0.x + dotnet-version: 8.0.x - name: Restore dependencies run: dotnet restore @@ -143,12 +141,12 @@ jobs: if: ${{ github.run_attempt != 1 }} needs: [ build-n-test, build-documentation ] # wait for build to finish steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup .NET - uses: actions/setup-dotnet@v2 + uses: actions/setup-dotnet@v4 with: - dotnet-version: 6.0.x + dotnet-version: 8.0.x - name: Restore dependencies run: dotnet restore @@ -190,7 +188,7 @@ jobs: - name: Print DOCUMENTATION_VERSION environment variable run: | echo 'Publishing documentation to ${{ env.GITHUB_PAGES_BRANCH }} for ${{ env.API_VERSION }} ${{ env.DOCUMENTATION_VERSION }}.' - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: ref: ${{ env.GITHUB_PAGES_BRANCH }} @@ -201,13 +199,13 @@ jobs: run: mkdir -p ./docs/${{ env.API_VERSION }}/${{ env.DOCUMENTATION_VERSION }} - name: Download documentation build artifact - uses: actions/download-artifact@v3.0.0 + uses: actions/download-artifact@v4 with: name: documentation-artifact path: ./docs/${{ env.API_VERSION }}/${{ env.DOCUMENTATION_VERSION }} - name: Create a pull request - uses: peter-evans/create-pull-request@v4.2.3 + uses: peter-evans/create-pull-request@v4 with: branch: ${{ env.GITHUB_PAGES_BRANCH }}-${{ env.API_VERSION }}-${{ env.DOCUMENTATION_VERSION }}-patch delete-branch: true diff --git a/.github/workflows/veracode-scan.yml b/.github/workflows/veracode-scan.yml index d29accd..6c98a1d 100644 --- a/.github/workflows/veracode-scan.yml +++ b/.github/workflows/veracode-scan.yml @@ -12,12 +12,12 @@ jobs: steps: - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup .NET - uses: actions/setup-dotnet@v2 + uses: actions/setup-dotnet@v4 with: - dotnet-version: 6.0.x + dotnet-version: 8.0.x - name: Restore dependencies run: dotnet restore --ignore-failed-sources diff --git a/CHANGELOG.md b/CHANGELOG.md index e2886a0..a617513 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Changelog +## 1.0.2 + +### Chore & Maintenance + +- Update version of `Laserfiche.Api.Client.Core` to `1.3.6` + ## 1.0.1 ### Chore & Maintenance diff --git a/LICENSE b/LICENSE index 65fabf6..9cf1062 100644 --- a/LICENSE +++ b/LICENSE @@ -1,7 +1,5 @@ MIT License -Copyright (c) 2022 Laserfiche - Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights diff --git a/Laserfiche.Repository.Api.Client.sln b/Laserfiche.Repository.Api.Client.sln index 7f4c974..b763c20 100644 --- a/Laserfiche.Repository.Api.Client.sln +++ b/Laserfiche.Repository.Api.Client.sln @@ -12,6 +12,11 @@ EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{820A4706-DE2D-4F9E-8760-AD027DC8304A}" ProjectSection(SolutionItems) = preProject .editorconfig = .editorconfig + CHANGELOG.md = CHANGELOG.md + CODE_OF_CONDUCT.md = CODE_OF_CONDUCT.md + LICENSE = LICENSE + MIGRATION_GUIDE.md = MIGRATION_GUIDE.md + README.md = README.md EndProjectSection EndProject Global diff --git a/src/Clients/AttributesClient.cs b/src/Clients/AttributesClient.cs index 1cb45c0..72f3046 100644 --- a/src/Clients/AttributesClient.cs +++ b/src/Clients/AttributesClient.cs @@ -44,6 +44,8 @@ partial interface IAttributesClient /// partial class AttributesClient { +#pragma warning disable CS1591 // Missing XML comment for publicly visible type or member + public async Task ListAttributesForEachAsync(Func> callback, ListAttributesParameters parameters, int? maxPageSize = null, CancellationToken cancellationToken = default) { // Initial request @@ -61,5 +63,7 @@ public async Task ListAttributesNextLinkAsync(strin { return await GetNextLinkAsync(_httpClient, nextLink, MergeMaxSizeIntoPrefer(maxPageSize, null), ListAttributesSendAsync, cancellationToken).ConfigureAwait(false); } + +#pragma warning restore CS1591 // Missing XML comment for publicly visible type or member } } diff --git a/src/Clients/BaseClient.cs b/src/Clients/BaseClient.cs index 3a14b6e..35e2c36 100644 --- a/src/Clients/BaseClient.cs +++ b/src/Clients/BaseClient.cs @@ -16,6 +16,8 @@ namespace Laserfiche.Repository.Api.Client /// public abstract class BaseClient { +#pragma warning disable CS1591 // Missing XML comment for publicly visible type or member + protected void UpdateJsonSerializerSettings(Newtonsoft.Json.JsonSerializerSettings settings) { settings.MaxDepth = 128; @@ -76,7 +78,7 @@ private string ConvertToString(object value, CultureInfo cultureInfo) if (name != null) { var field = IntrospectionExtensions.GetTypeInfo(value.GetType()).GetDeclaredField(name); - if (field != null && + if (field != null && CustomAttributeExtensions.GetCustomAttribute(field, typeof(EnumMemberAttribute)) is EnumMemberAttribute attribute) { return attribute.Value ?? name; @@ -103,5 +105,7 @@ private string ConvertToString(object value, CultureInfo cultureInfo) var result = Convert.ToString(value, cultureInfo); return result ?? ""; } + +#pragma warning restore CS1591 // Missing XML comment for publicly visible type or member } } diff --git a/src/Clients/EntriesClient.cs b/src/Clients/EntriesClient.cs index 20d2b3a..049fc3b 100644 --- a/src/Clients/EntriesClient.cs +++ b/src/Clients/EntriesClient.cs @@ -135,6 +135,8 @@ partial interface IEntriesClient /// partial class EntriesClient { +#pragma warning disable CS1591 // Missing XML comment for publicly visible type or member + public async Task GetEntryAsync(string uriString, CancellationToken cancellationToken = default) { using (var request = new HttpRequestMessage()) @@ -217,5 +219,7 @@ public async Task ListTagsNextLinkAsync(string nextLink, { return await GetNextLinkAsync(_httpClient, nextLink, MergeMaxSizeIntoPrefer(maxPageSize, null), ListTagsSendAsync, cancellationToken).ConfigureAwait(false); } + +#pragma warning restore CS1591 // Missing XML comment for publicly visible type or member } } diff --git a/src/Clients/Extensions/ApiExceptionExtensions.cs b/src/Clients/Extensions/ApiExceptionExtensions.cs index 8dcee16..f6c9328 100644 --- a/src/Clients/Extensions/ApiExceptionExtensions.cs +++ b/src/Clients/Extensions/ApiExceptionExtensions.cs @@ -1,4 +1,4 @@ -// Copyright (c) Laserfiche. +// Copyright (c) Laserfiche. // Licensed under the MIT License. See LICENSE in the project root for license information. using Laserfiche.Api.Client; using Newtonsoft.Json; @@ -24,4 +24,4 @@ internal static ApiException Create(int statusCode, IReadOnlyDictionary partial class FieldDefinitionsClient { +#pragma warning disable CS1591 // Missing XML comment for publicly visible type or member + public async Task ListFieldDefinitionsForEachAsync(Func> callback, ListFieldDefinitionsParameters parameters, int? maxPageSize = null, CancellationToken cancellationToken = default) { // Initial request @@ -62,5 +64,8 @@ public async Task ListFieldDefinitionsNextLin { return await GetNextLinkAsync(_httpClient, nextLink, MergeMaxSizeIntoPrefer(maxPageSize, null), ListFieldDefinitionsSendAsync, cancellationToken).ConfigureAwait(false); } + + +#pragma warning restore CS1591 // Missing XML comment for publicly visible type or member } } diff --git a/src/Clients/LinkDefinitionsClient.cs b/src/Clients/LinkDefinitionsClient.cs index 9eaf293..99632bc 100644 --- a/src/Clients/LinkDefinitionsClient.cs +++ b/src/Clients/LinkDefinitionsClient.cs @@ -45,6 +45,8 @@ partial interface ILinkDefinitionsClient /// partial class LinkDefinitionsClient { +#pragma warning disable CS1591 // Missing XML comment for publicly visible type or member + public async Task ListLinkDefinitionsForEachAsync(Func> callback, ListLinkDefinitionsParameters parameters, int? maxPageSize = null, CancellationToken cancellationToken = default) { // Initial request @@ -62,5 +64,8 @@ public async Task ListLinkDefinitionsNextLinkA { return await GetNextLinkAsync(_httpClient, nextLink, MergeMaxSizeIntoPrefer(maxPageSize, null), ListLinkDefinitionsSendAsync, cancellationToken).ConfigureAwait(false); } + + +#pragma warning restore CS1591 // Missing XML comment for publicly visible type or member } } diff --git a/src/Clients/SearchesClient.cs b/src/Clients/SearchesClient.cs index 951fd9f..5aa4e9d 100644 --- a/src/Clients/SearchesClient.cs +++ b/src/Clients/SearchesClient.cs @@ -2,7 +2,6 @@ // Licensed under the MIT License. See LICENSE in the project root for license information. using Laserfiche.Api.Client; using System; -using System.Collections.Generic; using System.Threading; using System.Threading.Tasks; @@ -71,6 +70,8 @@ partial interface ISearchesClient /// partial class SearchesClient { +#pragma warning disable CS1591 // Missing XML comment for publicly visible type or member + public async Task ListSearchResultsForEachAsync(Func> callback, ListSearchResultsParameters parameters, int? maxPageSize = null, CancellationToken cancellationToken = default) { // Initial request @@ -106,5 +107,7 @@ public async Task ListSearchContextHitsNextL { return await GetNextLinkAsync(_httpClient, nextLink, MergeMaxSizeIntoPrefer(maxPageSize, null), ListSearchContextHitsSendAsync, cancellationToken).ConfigureAwait(false); } + +#pragma warning restore CS1591 // Missing XML comment for publicly visible type or member } } diff --git a/src/Clients/TagDefinitionsClient.cs b/src/Clients/TagDefinitionsClient.cs index 000d469..1133038 100644 --- a/src/Clients/TagDefinitionsClient.cs +++ b/src/Clients/TagDefinitionsClient.cs @@ -44,6 +44,8 @@ partial interface ITagDefinitionsClient /// partial class TagDefinitionsClient { +#pragma warning disable CS1591 // Missing XML comment for publicly visible type or member + public async Task ListTagDefinitionsForEachAsync(Func> callback, ListTagDefinitionsParameters parameters, int? maxPageSize = null, CancellationToken cancellationToken = default) { // Initial request @@ -61,5 +63,7 @@ public async Task ListTagDefinitionsNextLinkAsy { return await GetNextLinkAsync(_httpClient, nextLink, MergeMaxSizeIntoPrefer(maxPageSize, null), ListTagDefinitionsSendAsync, cancellationToken).ConfigureAwait(false); } + +#pragma warning restore CS1591 // Missing XML comment for publicly visible type or member } } diff --git a/src/Clients/TemplateDefinitionsClient.cs b/src/Clients/TemplateDefinitionsClient.cs index cf6f3b7..f4dde75 100644 --- a/src/Clients/TemplateDefinitionsClient.cs +++ b/src/Clients/TemplateDefinitionsClient.cs @@ -96,6 +96,8 @@ partial interface ITemplateDefinitionsClient /// partial class TemplateDefinitionsClient { +#pragma warning disable CS1591 // Missing XML comment for publicly visible type or member + public async Task ListTemplateDefinitionsForEachAsync(Func> callback, ListTemplateDefinitionsParameters parameters, int? maxPageSize = null, CancellationToken cancellationToken = default) { // Initial request @@ -149,5 +151,7 @@ public async Task ListTemplateFieldDe { return await GetNextLinkAsync(_httpClient, nextLink, MergeMaxSizeIntoPrefer(maxPageSize, null), ListTemplateFieldDefinitionsByTemplateIdSendAsync, cancellationToken).ConfigureAwait(false); } + +#pragma warning restore CS1591 // Missing XML comment for publicly visible type or member } } diff --git a/src/Laserfiche.Repository.Api.Client.csproj b/src/Laserfiche.Repository.Api.Client.csproj index 6967014..b382c09 100644 --- a/src/Laserfiche.Repository.Api.Client.csproj +++ b/src/Laserfiche.Repository.Api.Client.csproj @@ -2,7 +2,7 @@ netstandard2.0 - 1.0.1 + 1.0.2 Laserfiche The .NET Laserfiche Repository API client library for accessing the v2 Laserfiche Repository APIs. Copyright 2023 Laserfiche @@ -22,7 +22,7 @@ - + diff --git a/src/RepositoryApiClient.cs b/src/RepositoryApiClient.cs index ff2aa8a..77ffbc9 100644 --- a/src/RepositoryApiClient.cs +++ b/src/RepositoryApiClient.cs @@ -2,9 +2,11 @@ // Licensed under the MIT License. See LICENSE in the project root for license information. using Laserfiche.Api.Client.HttpHandlers; using Laserfiche.Api.Client.OAuth; +using Laserfiche.Api.Client.Utils; using System; using System.Net.Http; using System.Net.Http.Headers; +using static Laserfiche.Api.Client.HttpHandlers.ApiHttpMessageHandler; namespace Laserfiche.Repository.Api.Client { @@ -13,7 +15,7 @@ namespace Laserfiche.Repository.Api.Client /// public class RepositoryApiClient : IRepositoryApiClient { - private const string DefaultBaseAddress = "https://dummy.example.com/repository/"; + private const string DummyBaseAddress = "http://example.com/"; private readonly HttpClient _httpClient; /// @@ -65,29 +67,29 @@ internal RepositoryApiClient(HttpClient httpClient) /// /// Create a Laserfiche repository client. /// - /// The http request handler for the Laserfiche repository client. + /// The http request handler for the Laserfiche APIs. /// (optional) Override for the Laserfiche repository API base url. - /// IRepositoryApiClient + /// IRepositoryApiClient public static IRepositoryApiClient CreateFromHttpRequestHandler(IHttpRequestHandler httpRequestHandler, string baseUrlDebug = null) { if (httpRequestHandler == null) throw new ArgumentNullException(nameof(httpRequestHandler)); + GetApiBaseUri getApiBaseUri; if (!string.IsNullOrEmpty(baseUrlDebug)) - baseUrlDebug = baseUrlDebug.TrimEnd('/') + "/"; - - var repositoryClientHandler = new RepositoryApiClientHandler(httpRequestHandler, baseUrlDebug); - var httpClient = new HttpClient(repositoryClientHandler); - - if (httpRequestHandler is UsernamePasswordHandler) { - httpClient.BaseAddress = new Uri(baseUrlDebug); + baseUrlDebug = baseUrlDebug.TrimEnd('/') + "/"; + getApiBaseUri = (_) => baseUrlDebug; } else { - httpClient.BaseAddress = new Uri(DefaultBaseAddress); + getApiBaseUri = (domain) => DomainUtils.GetRepositoryApiBaseUri(domain); + baseUrlDebug = DummyBaseAddress; } + var apiHttpMessageHandler = new ApiHttpMessageHandler(httpRequestHandler, getApiBaseUri); + var httpClient = new HttpClient(apiHttpMessageHandler); + httpClient.BaseAddress = new Uri(baseUrlDebug); var repositoryClient = new RepositoryApiClient(httpClient); return repositoryClient; } diff --git a/src/RepositoryApiClientHandler.cs b/src/RepositoryApiClientHandler.cs deleted file mode 100644 index 1929de3..0000000 --- a/src/RepositoryApiClientHandler.cs +++ /dev/null @@ -1,88 +0,0 @@ -// Copyright (c) Laserfiche. -// Licensed under the MIT License. See LICENSE in the project root for license information. -using Laserfiche.Api.Client.HttpHandlers; -using Laserfiche.Api.Client.Utils; -using System; -using System.Net; -using System.Net.Http; -using System.Threading; -using System.Threading.Tasks; - -namespace Laserfiche.Repository.Api.Client -{ - internal class RepositoryApiClientHandler : DelegatingHandler - { - private readonly IHttpRequestHandler _httpRequestHandler; - private readonly string _baseUrlDebug; - private Uri _baseAddress; - - public RepositoryApiClientHandler(IHttpRequestHandler httpRequestHandler, string baseUrlDebug) : base(new HttpClientHandler() { AutomaticDecompression = DecompressionMethods.GZip }) - { - _httpRequestHandler = httpRequestHandler ?? throw new ArgumentNullException(nameof(httpRequestHandler)); - _baseUrlDebug = baseUrlDebug; - } - - protected override async Task SendAsync(HttpRequestMessage request, CancellationToken cancellationToken) - { - return await SendExAsync(request, cancellationToken, true).ConfigureAwait(false) - ?? await SendExAsync(request, cancellationToken, false).ConfigureAwait(false); - } - - private async Task SendExAsync(HttpRequestMessage request, CancellationToken cancellationToken, bool returnNullIfRetriable) - { - HttpResponseMessage response; - - // Sets the authorization header - var beforeSendResult = await _httpRequestHandler.BeforeSendAsync(request, cancellationToken).ConfigureAwait(false); - - if (_baseAddress == null || (_baseUrlDebug == null && !_baseAddress.Host.EndsWith(beforeSendResult.RegionalDomain))) - { - _baseAddress = GetBaseAddress(beforeSendResult.RegionalDomain); - } - request.RequestUri = new Uri(_baseAddress, request.RequestUri.PathAndQuery); - - try - { - response = await base.SendAsync(request, cancellationToken).ConfigureAwait(false); - if (returnNullIfRetriable && IsTransientHttpStatusCode(response.StatusCode) && IsIdempotentHttpMethod(request.Method)) - { - return null; - } - } - catch - { - if (returnNullIfRetriable) - { - return null; - } - else - { - throw; - } - } - - bool shouldRetry = await _httpRequestHandler.AfterSendAsync(response, cancellationToken).ConfigureAwait(false); - if (returnNullIfRetriable && shouldRetry) - { - return null; - } - return response; - } - - private Uri GetBaseAddress(string domain) - { - string baseAddress = _baseUrlDebug ?? DomainUtils.GetRepositoryApiBaseUri(domain); - return new Uri(baseAddress); - } - - private static bool IsTransientHttpStatusCode(HttpStatusCode statusCode) - { - return (int)statusCode >= 500 || statusCode == HttpStatusCode.RequestTimeout; - } - - private static bool IsIdempotentHttpMethod(HttpMethod method) - { - return method == HttpMethod.Get || method == HttpMethod.Put || method == HttpMethod.Options; - } - } -} diff --git a/tests/integration/Laserfiche.Repository.Api.Client.IntegrationTest.csproj b/tests/integration/Laserfiche.Repository.Api.Client.IntegrationTest.csproj index 722a01d..aaa97fe 100644 --- a/tests/integration/Laserfiche.Repository.Api.Client.IntegrationTest.csproj +++ b/tests/integration/Laserfiche.Repository.Api.Client.IntegrationTest.csproj @@ -1,7 +1,7 @@  - net6.0 + net8.0 false Laserfiche Apache License 2.0 @@ -11,10 +11,13 @@ - - - - + + + + + all + runtime; build; native; contentfiles; analyzers; buildtransitive + diff --git a/tests/unit/Custom/ApiExceptionExtensionsTest.cs b/tests/unit/Custom/ApiExceptionExtensionsTest.cs index 3506099..98ff1f6 100644 --- a/tests/unit/Custom/ApiExceptionExtensionsTest.cs +++ b/tests/unit/Custom/ApiExceptionExtensionsTest.cs @@ -12,7 +12,7 @@ public class ApiExceptionExtensionsTest { private const string OPERATION_ID_HEADER = "X-RequestId"; - private void AssertApiExceptionAreEqual(ApiException expected, ApiException actual) + private static void AssertApiExceptionAreEqual(ApiException expected, ApiException actual) { Assert.Equal(expected.StatusCode, actual.StatusCode); Assert.Equal(expected.Message, actual.Message); @@ -117,4 +117,4 @@ public void Create_WithResponseString_ResponseStringIsProblemDetails_ExceptionHa AssertApiExceptionAreEqual(expectedException, actualException); } } -} +} \ No newline at end of file diff --git a/tests/unit/Custom/LaserficheRepositoryApiClientCustomTest.cs b/tests/unit/Custom/LaserficheRepositoryApiClientCustomTest.cs deleted file mode 100644 index 7f42766..0000000 --- a/tests/unit/Custom/LaserficheRepositoryApiClientCustomTest.cs +++ /dev/null @@ -1,40 +0,0 @@ -// Copyright (c) Laserfiche. -// Licensed under the MIT License. See LICENSE in the project root for license information. -using Moq; -using Moq.Protected; -using Newtonsoft.Json; -using System; -using System.Net; -using System.Net.Http; -using System.Net.Http.Headers; -using System.Threading; -using System.Threading.Tasks; -using Xunit; - -namespace Laserfiche.Repository.Api.Client.Test.Custom -{ - public class LaserficheRepositoryApiClientCustomTest - { - #region GetEntryAsync with url - [Fact] - public void GetEntryAsync_InvalidEntryId() - { - string uriString = "http://host.laserfiche.com/wrongversion/Repositories/repo123/Entries/abc?$select=1"; - - var client = new RepositoryApiClient(null); - - Assert.ThrowsAsync(() => client.EntriesClient.GetEntryAsync(uriString)); - } - - [Fact] - public void GetEntryAsync_InvalidUri() - { - string uriString = "http://host.laserfiche.com/wrongversion/Repositories/repo123/Entries/456?$select=1"; - - var client = new RepositoryApiClient(null); - - Assert.ThrowsAsync(() => client.EntriesClient.GetEntryAsync(uriString)); - } - #endregion - } -} diff --git a/tests/unit/Laserfiche.Repository.Api.Client.Test.csproj b/tests/unit/Laserfiche.Repository.Api.Client.Test.csproj index 201caa4..2423641 100644 --- a/tests/unit/Laserfiche.Repository.Api.Client.Test.csproj +++ b/tests/unit/Laserfiche.Repository.Api.Client.Test.csproj @@ -1,7 +1,7 @@ - net6.0 + net8.0 false Laserfiche Apache License 2.0 @@ -10,11 +10,17 @@ - + - - - + + + all + runtime; build; native; contentfiles; analyzers; buildtransitive + + + all + runtime; build; native; contentfiles; analyzers; buildtransitive +