From 81ba6e456b3d2b31f4d53c05763c5088d25f39e9 Mon Sep 17 00:00:00 2001 From: Bernd Schoolmann Date: Tue, 18 Mar 2025 14:48:36 +0100 Subject: [PATCH] Attempt to fix tests --- src/Api/Auth/Controllers/AccountsController.cs | 6 +----- test/Api.Test/Auth/Controllers/AccountsControllerTests.cs | 6 +----- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/src/Api/Auth/Controllers/AccountsController.cs b/src/Api/Auth/Controllers/AccountsController.cs index 0a3b31a74a..f1998d8266 100644 --- a/src/Api/Auth/Controllers/AccountsController.cs +++ b/src/Api/Auth/Controllers/AccountsController.cs @@ -15,7 +15,6 @@ using Bit.Core.AdminConsole.Services; using Bit.Core.Auth.Entities; using Bit.Core.Auth.Models.Api.Request.Accounts; using Bit.Core.Auth.Models.Data; -using Bit.Core.Auth.Services; using Bit.Core.Auth.UserFeatures.TdeOffboardingPassword.Interfaces; using Bit.Core.Auth.UserFeatures.UserMasterPassword.Interfaces; using Bit.Core.Entities; @@ -58,7 +57,6 @@ public class AccountsController : Controller _organizationUserValidator; private readonly IRotationValidator, IEnumerable> _webauthnKeyValidator; - private readonly IOpaqueKeyExchangeService _opaqueKeyExchangeService; public AccountsController( @@ -78,8 +76,7 @@ public class AccountsController : Controller emergencyAccessValidator, IRotationValidator, IReadOnlyList> organizationUserValidator, - IRotationValidator, IEnumerable> webAuthnKeyValidator, - IOpaqueKeyExchangeService opaqueKeyExchangeService + IRotationValidator, IEnumerable> webAuthnKeyValidator ) { _organizationService = organizationService; @@ -97,7 +94,6 @@ public class AccountsController : Controller _emergencyAccessValidator = emergencyAccessValidator; _organizationUserValidator = organizationUserValidator; _webauthnKeyValidator = webAuthnKeyValidator; - _opaqueKeyExchangeService = opaqueKeyExchangeService; } diff --git a/test/Api.Test/Auth/Controllers/AccountsControllerTests.cs b/test/Api.Test/Auth/Controllers/AccountsControllerTests.cs index a09a53e5b7..e5b47d7c9c 100644 --- a/test/Api.Test/Auth/Controllers/AccountsControllerTests.cs +++ b/test/Api.Test/Auth/Controllers/AccountsControllerTests.cs @@ -13,7 +13,6 @@ using Bit.Core.AdminConsole.Services; using Bit.Core.Auth.Entities; using Bit.Core.Auth.Models.Api.Request.Accounts; using Bit.Core.Auth.Models.Data; -using Bit.Core.Auth.Services; using Bit.Core.Auth.UserFeatures.TdeOffboardingPassword.Interfaces; using Bit.Core.Auth.UserFeatures.UserMasterPassword.Interfaces; using Bit.Core.Entities; @@ -54,7 +53,6 @@ public class AccountsControllerTests : IDisposable _resetPasswordValidator; private readonly IRotationValidator, IEnumerable> _webauthnKeyRotationValidator; - private readonly IOpaqueKeyExchangeService _opaqueKeyExchangeService; public AccountsControllerTests() @@ -79,7 +77,6 @@ public class AccountsControllerTests : IDisposable _resetPasswordValidator = Substitute .For, IReadOnlyList>>(); - _opaqueKeyExchangeService = Substitute.For(); _sut = new AccountsController( _organizationService, @@ -96,8 +93,7 @@ public class AccountsControllerTests : IDisposable _sendValidator, _emergencyAccessValidator, _resetPasswordValidator, - _webauthnKeyRotationValidator, - _opaqueKeyExchangeService + _webauthnKeyRotationValidator ); }