Skip to content

Commit 3ef2bc8

Browse files
committed
test(build): new build test
1 parent 8d7b22a commit 3ef2bc8

File tree

3 files changed

+10
-8
lines changed

3 files changed

+10
-8
lines changed

src/NetDevPack.Security.Jwt.Core/DefaultStore/InMemoryStore.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ internal class InMemoryStore : IJsonWebKeyStore
1313

1414
public Task Store(KeyMaterial keyMaterial)
1515
{
16+
if (keyMaterial is null) throw new InvalidOperationException("Can't store empty value.");
17+
1618
_slim.Wait();
1719
_store.Add(keyMaterial);
1820
_slim.Release();

src/NetDevPack.Security.Jwt.Store.FileSystem/FileSystemStore.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ private string GetCurrentFile(JwtKeyType jwtKeyType)
3030
{
3131
var files = Directory.GetFiles(KeysPath.FullName, $"*current*.{jwtKeyType}.key");
3232
if (files.Any())
33-
return Path.Combine(KeysPath.FullName, files.First());
33+
return files.First();
3434

3535
return Path.Combine(KeysPath.FullName, $"{_options.Value.KeyPrefix}current.{jwtKeyType}.key");
3636
}

tests/NetDevPack.Security.Jwt.Tests/StoreTests/FileSystemStoreTests.cs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@
33

44
namespace NetDevPack.Security.Jwt.Tests.StoreTests
55
{
6-
//[Trait("Category", "InMemory Tests")]
7-
//public class FileSystemStoreTests : GenericStoreServiceTest<WarmupFileStore>
8-
//{
9-
// public FileSystemStoreTests(WarmupFileStore unifiedContext) : base(unifiedContext)
10-
// {
11-
// }
6+
[Trait("Category", "InMemory Tests")]
7+
public class FileSystemStoreTests : GenericStoreServiceTest<WarmupFileStore>
8+
{
9+
public FileSystemStoreTests(WarmupFileStore unifiedContext) : base(unifiedContext)
10+
{
11+
}
1212

13-
//}
13+
}
1414
}

0 commit comments

Comments
 (0)