Skip to content

Commit

Permalink
upd
Browse files Browse the repository at this point in the history
  • Loading branch information
iatsuta committed Nov 18, 2024
1 parent 7adffde commit 575ff25
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@ public static ISecuritySystemSettings AddSecurityRoles(this ISecuritySystemSetti
SampleSystemSecurityRole.SeManager,
new SecurityRoleInfo(new Guid("dbf3556d-7106-4175-b5e4-a32d00bd857a"))
{
Children = [SampleSystemSecurityRole.TestVirtualRole]
Children = [SampleSystemSecurityRole.TestVirtualRole],
Operations = [SampleSystemSecurityOperation.BusinessUnitEdit]
})

.AddSecurityRole(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ public void LoadTreeWithMiddlePermission_RootParentLoadedWithViewMode()

var userId = this.AuthHelper.SetUserRole(
TextRandomizer.RandomString(10),
new SampleSystemTestPermission(SecurityRole.Administrator, childBu));
new SampleSystemTestPermission(SampleSystemSecurityRole.SeManager, childBu));

// Act
var result = this.Evaluate(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using Automation.ServiceEnvironment;

using Automation.ServiceEnvironment;

using FluentAssertions;

Expand All @@ -9,6 +10,7 @@
using SampleSystem.Domain;
using SampleSystem.Generated.DTO;
using SampleSystem.IntegrationTests.__Support.TestData;
using SampleSystem.Security;
using SampleSystem.WebApiCore.Controllers.Main;

namespace SampleSystem.IntegrationTests;
Expand Down Expand Up @@ -45,7 +47,7 @@ public void SetUp()

this.DataHelper.SaveEmployee(login: TestEmployeeLogin);

this.AuthHelper.SetUserRole(TestEmployeeLogin, new SampleSystemTestPermission(SecurityRole.Administrator, this.bu2Ident, null, null));
this.AuthHelper.SetUserRole(TestEmployeeLogin, new SampleSystemTestPermission(SampleSystemSecurityRole.SeManager, this.bu2Ident));

this.EvaluateWrite(
context =>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ public void SetUp()

this.AuthHelper.SetUserRole(
this.TestEmployee.Id,
new SampleSystemTestPermission(SecurityRole.Administrator, this.bu2Ident, null, this.loc1Ident),
new SampleSystemTestPermission(SecurityRole.Administrator, this.bu2Ident, null, this.loc2Ident));
new SampleSystemTestPermission(SampleSystemSecurityRole.SeManager, this.bu2Ident, null, this.loc1Ident),
new SampleSystemTestPermission(SampleSystemSecurityRole.SeManager, this.bu2Ident, null, this.loc2Ident));

this.TestEmp1 = this.DataHelper.SaveEmployee(coreBusinessUnit: this.bu1Ident, location: this.loc1Ident);

Expand Down

0 comments on commit 575ff25

Please sign in to comment.