refactor(configmanager): simplify SecureStore UI with unified info view
Consolidate SecureStoreLockedFormView and SecureStoreUnlockedFormView into a single SecureStoreInfoFormView that displays store status and metadata. Simplifies MainWindowViewModel by removing redundant state management. Also adds design docs for RegexTransformer feature.
This commit is contained in:
-41
@@ -59,31 +59,6 @@ public class SecureStoreManagerTests : IDisposable
|
||||
File.Exists(keyPath).ShouldBeTrue();
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void CreateStoreWithPassword_CreatesStore()
|
||||
{
|
||||
// Arrange
|
||||
var storePath = Path.Combine(_testDirectory, "test.json");
|
||||
|
||||
// Act
|
||||
_sut.CreateStoreWithPassword(storePath, "testpassword123");
|
||||
|
||||
// Assert
|
||||
_sut.IsStoreOpen.ShouldBeTrue();
|
||||
_sut.CurrentStorePath.ShouldBe(storePath);
|
||||
File.Exists(storePath).ShouldBeTrue();
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void CreateStoreWithPassword_WithEmptyPassword_ThrowsArgumentException()
|
||||
{
|
||||
// Arrange
|
||||
var storePath = Path.Combine(_testDirectory, "test.json");
|
||||
|
||||
// Act & Assert
|
||||
Should.Throw<ArgumentException>(() => _sut.CreateStoreWithPassword(storePath, ""));
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void OpenStore_WithValidKeyFile_OpensStore()
|
||||
{
|
||||
@@ -112,22 +87,6 @@ public class SecureStoreManagerTests : IDisposable
|
||||
Should.Throw<FileNotFoundException>(() => _sut.OpenStore(storePath, keyPath));
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void OpenStoreWithPassword_OpensStore()
|
||||
{
|
||||
// Arrange
|
||||
var storePath = Path.Combine(_testDirectory, "test.json");
|
||||
var password = "testpassword123";
|
||||
_sut.CreateStoreWithPassword(storePath, password);
|
||||
_sut.CloseStore();
|
||||
|
||||
// Act
|
||||
_sut.OpenStoreWithPassword(storePath, password);
|
||||
|
||||
// Assert
|
||||
_sut.IsStoreOpen.ShouldBeTrue();
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void CloseStore_ClosesOpenStore()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user