diff --git a/src/Umbraco.Tests.UnitTests/Umbraco.Web.BackOffice/Security/BackOfficeCookieManagerTests.cs b/src/Umbraco.Tests.UnitTests/Umbraco.Web.BackOffice/Security/BackOfficeCookieManagerTests.cs index 3270a003f5..342083039f 100644 --- a/src/Umbraco.Tests.UnitTests/Umbraco.Web.BackOffice/Security/BackOfficeCookieManagerTests.cs +++ b/src/Umbraco.Tests.UnitTests/Umbraco.Web.BackOffice/Security/BackOfficeCookieManagerTests.cs @@ -60,6 +60,8 @@ namespace Umbraco.Tests.UnitTests.Umbraco.Web.Backoffice.Security var runtime = Mock.Of(x => x.Level == RuntimeLevel.Run); + GenerateAuthPaths(out var remainingTimeoutSecondsPath, out var isAuthPath); + var mgr = new BackOfficeCookieManager( Mock.Of(), runtime, @@ -67,8 +69,6 @@ namespace Umbraco.Tests.UnitTests.Umbraco.Web.Backoffice.Security globalSettings, Mock.Of()); - GenerateAuthPaths(out var remainingTimeoutSecondsPath, out var isAuthPath); - var result = mgr.ShouldAuthenticateRequest(new Uri($"http://localhost{remainingTimeoutSecondsPath}")); Assert.IsTrue(result); @@ -88,7 +88,7 @@ namespace Umbraco.Tests.UnitTests.Umbraco.Web.Backoffice.Security runtime, Mock.Of(x => x.ApplicationVirtualPath == "/" && x.ToAbsolute(globalSettings.UmbracoPath) == "/umbraco" && x.ToAbsolute(Constants.SystemDirectories.Install) == "/install"), globalSettings, - Mock.Of(x => x.IsAvailable && x.Get(Constants.Security.ForceReAuthFlag) == "not null")); + Mock.Of(x => x.IsAvailable == true && x.Get(Constants.Security.ForceReAuthFlag) == "not null")); var result = mgr.ShouldAuthenticateRequest(new Uri($"http://localhost/notbackoffice")); Assert.IsTrue(result); diff --git a/src/Umbraco.Web.Common/Security/UmbracoUserManager.cs b/src/Umbraco.Web.Common/Security/UmbracoUserManager.cs index a555cca4be..675262fd7a 100644 --- a/src/Umbraco.Web.Common/Security/UmbracoUserManager.cs +++ b/src/Umbraco.Web.Common/Security/UmbracoUserManager.cs @@ -12,7 +12,6 @@ using Umbraco.Core.Models.Identity; using Umbraco.Core.Security; using Umbraco.Net; - namespace Umbraco.Web.Common.Security {