mirror of
https://github.com/BinaryAlley/Nemera.git
synced 2026-12-03 07:11:10 +00:00
Implements tests for commit 8a5cb9116e
This commit is contained in:
1 parent
73ed952ded
commit
94a67aded4
32 files changed
+1751
-2
No files matched your search
+24
@@ -0,0 +1,24 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using Lumina.Application.Common.Infrastructure.Authorization;
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Application.UnitTests.Common.Infrastructure.Authorization;
|
||||
|
||||
/// <summary>
|
||||
/// Contains unit tests for the <see cref="AuthorizationRoles"/> class.
|
||||
/// </summary>
|
||||
[ExcludeFromCodeCoverage]
|
||||
public class AuthorizationRolesTests
|
||||
{
|
||||
[Fact]
|
||||
public void ADMIN_WhenRead_ShouldBeAdmin()
|
||||
{
|
||||
// The role name is written into seeded database rows and compared during authorization checks, so it must stay stable across releases.
|
||||
// Act
|
||||
string role = AuthorizationRoles.ADMIN;
|
||||
|
||||
// Assert
|
||||
Assert.Equal("Admin", role);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user