diff --git a/samples/BlazorServer/BlazorServer.csproj b/samples/BlazorServer/BlazorServer.csproj index 98d95a3..d65420f 100644 --- a/samples/BlazorServer/BlazorServer.csproj +++ b/samples/BlazorServer/BlazorServer.csproj @@ -1,11 +1,11 @@  - net7.0 + net8.0 - + diff --git a/samples/BlazorWebAssembly/BlazorWebAssembly.csproj b/samples/BlazorWebAssembly/BlazorWebAssembly.csproj index f1d4e0d..e84674a 100644 --- a/samples/BlazorWebAssembly/BlazorWebAssembly.csproj +++ b/samples/BlazorWebAssembly/BlazorWebAssembly.csproj @@ -1,13 +1,13 @@  - net7.0 + net8.0 - - - + + + diff --git a/samples/bUnitExample/bUnitExample.csproj b/samples/bUnitExample/bUnitExample.csproj index 5d0efb7..622e902 100644 --- a/samples/bUnitExample/bUnitExample.csproj +++ b/samples/bUnitExample/bUnitExample.csproj @@ -1,18 +1,18 @@ - net7.0 + net8.0 - - - - + + + + runtime; build; native; contentfiles; analyzers; buildtransitive all - + runtime; build; native; contentfiles; analyzers; buildtransitive all diff --git a/src/Blazored.SessionStorage.TestExtensions/Blazored.SessionStorage.TestExtensions.csproj b/src/Blazored.SessionStorage.TestExtensions/Blazored.SessionStorage.TestExtensions.csproj index 40800be..783183b 100644 --- a/src/Blazored.SessionStorage.TestExtensions/Blazored.SessionStorage.TestExtensions.csproj +++ b/src/Blazored.SessionStorage.TestExtensions/Blazored.SessionStorage.TestExtensions.csproj @@ -1,7 +1,7 @@  - net6.0;net7.0 + net6.0;net7.0;net8.0 Chris Sainty @@ -35,7 +35,7 @@ - + diff --git a/src/Blazored.SessionStorage/Blazored.SessionStorage.csproj b/src/Blazored.SessionStorage/Blazored.SessionStorage.csproj index 07ebd5d..07cd97b 100644 --- a/src/Blazored.SessionStorage/Blazored.SessionStorage.csproj +++ b/src/Blazored.SessionStorage/Blazored.SessionStorage.csproj @@ -1,7 +1,7 @@  - net6.0;net7.0 + net6.0;net7.0;net8.0 Chris Sainty @@ -37,6 +37,10 @@ + + + + diff --git a/tests/Blazored.SessionStorage.Tests/Blazored.SessionStorage.Tests.csproj b/tests/Blazored.SessionStorage.Tests/Blazored.SessionStorage.Tests.csproj index 00c5d20..1c6ffaa 100644 --- a/tests/Blazored.SessionStorage.Tests/Blazored.SessionStorage.Tests.csproj +++ b/tests/Blazored.SessionStorage.Tests/Blazored.SessionStorage.Tests.csproj @@ -1,7 +1,7 @@ - net7.0 + net8.0 false @@ -11,16 +11,16 @@ - - - - - - + + + + + + all runtime; build; native; contentfiles; analyzers; buildtransitive - + all runtime; build; native; contentfiles; analyzers; buildtransitive diff --git a/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/GetItemAsStringAsync.cs b/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/GetItemAsStringAsync.cs index a3dedb7..10a64c9 100644 --- a/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/GetItemAsStringAsync.cs +++ b/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/GetItemAsStringAsync.cs @@ -35,13 +35,13 @@ public GetItemAsStringAsync() [InlineData("")] [InlineData(" ")] [InlineData(null)] - public void ThrowsArgumentNullException_When_KeyIsInvalid(string key) + public async Task ThrowsArgumentNullException_When_KeyIsInvalid(string key) { // arrange / act var action = new Func(async () => await _sut.GetItemAsStringAsync(key)); // assert - Assert.ThrowsAsync(action); + await Assert.ThrowsAsync(action); } [Theory] @@ -75,4 +75,4 @@ public async Task ReturnsComplexObjectFromStore() var serializedData = _serializer.Serialize(objectToSave); Assert.Equal(serializedData, result); } -} \ No newline at end of file +} diff --git a/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/GetItemAsync.cs b/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/GetItemAsync.cs index 67de73f..02f5714 100644 --- a/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/GetItemAsync.cs +++ b/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/GetItemAsync.cs @@ -35,13 +35,13 @@ public GetItemAsync() [InlineData("")] [InlineData(" ")] [InlineData(null)] - public void ThrowsArgumentNullException_When_KeyIsInvalid(string key) + public async Task ThrowsArgumentNullException_When_KeyIsInvalid(string key) { // arrange / act var action = new Func(async () => await _sut.GetItemAsync(key)); // assert - Assert.ThrowsAsync(action); + await Assert.ThrowsAsync(action); } [Theory] @@ -102,4 +102,4 @@ public async Task ReturnsStringFromStore_When_JsonExceptionIsThrown() // Assert Assert.Equal(valueToSave, result); } -} \ No newline at end of file +} diff --git a/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/RemoveItemAsync.cs b/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/RemoveItemAsync.cs index cd138ee..fa0e631 100644 --- a/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/RemoveItemAsync.cs +++ b/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/RemoveItemAsync.cs @@ -34,13 +34,13 @@ public RemoveItemAsync() [InlineData("")] [InlineData(" ")] [InlineData(null)] - public void ThrowsArgumentNullException_When_KeyIsInvalid(string key) + public async Task ThrowsArgumentNullException_When_KeyIsInvalid(string key) { // arrange / act var action = new Func(async () => await _sut.RemoveItemAsync(key)); // assert - Assert.ThrowsAsync(action); + await Assert.ThrowsAsync(action); } [Fact] @@ -66,4 +66,4 @@ public async Task DoesNothingWhenItemDoesNotExistInStore() // Assert Assert.Equal(0, await _storageProvider.LengthAsync()); } -} \ No newline at end of file +} diff --git a/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/SetItemAsStringAsync.cs b/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/SetItemAsStringAsync.cs index 7857a1b..5d61006 100644 --- a/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/SetItemAsStringAsync.cs +++ b/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/SetItemAsStringAsync.cs @@ -34,25 +34,25 @@ public SetItemAsStringAsync() [InlineData("")] [InlineData(" ")] [InlineData(null)] - public void ThrowsArgumentNullException_When_KeyIsInvalid(string key) + public async Task ThrowsArgumentNullException_When_KeyIsInvalid(string key) { // arrange / act const string data = "Data"; var action = new Func(async () => await _sut.SetItemAsStringAsync(key, data)); // assert - Assert.ThrowsAsync(action); + await Assert.ThrowsAsync(action); } [Fact] - public void ThrowsArgumentNullException_When_DataIsNull() + public async Task ThrowsArgumentNullException_When_DataIsNull() { // arrange / act var data = (string)null; var action = new Func(async () => await _sut.SetItemAsStringAsync("MyValue", data)); // assert - Assert.ThrowsAsync(action); + await Assert.ThrowsAsync(action); } [Fact] @@ -201,4 +201,4 @@ public async Task OnChangedEventContainsOldValue_When_UpdatingExistingData() // assert Assert.Equal(existingValue, oldValue); } -} \ No newline at end of file +} diff --git a/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/SetItemAsync.cs b/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/SetItemAsync.cs index 8aa1e49..87c799b 100644 --- a/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/SetItemAsync.cs +++ b/tests/Blazored.SessionStorage.Tests/SessionStorageServiceTests/SetItemAsync.cs @@ -35,14 +35,14 @@ public SetItemAsync() [InlineData("")] [InlineData(" ")] [InlineData(null)] - public void ThrowsArgumentNullException_When_KeyIsInvalid(string key) + public async Task ThrowsArgumentNullException_When_KeyIsInvalid(string key) { // arrange / act const string data = "Data"; var action = new Func(async () => await _sut.SetItemAsync(key, data)); // assert - Assert.ThrowsAsync(action); + await Assert.ThrowsAsync(action); } [Fact] @@ -231,4 +231,4 @@ public async Task OnChangedEventContainsOldValue_When_UpdatingExistingData() // assert Assert.Equal(existingValue, oldValue); } -} \ No newline at end of file +}