public IAppSettings GetAppSettingWithMocks(out IFileSystem fileSystem) { fileSystem = new PlaceholderFileSystem(); return(new AppSettings( fileSystem, new CryptoService() )); }
public void VerifyMemoryFileSystemDoesNotBreak() { PlaceholderFileSystem service = new PlaceholderFileSystem(); Assert.False(service.Exists(service.GetFullPath("./"))); Assert.Equal("", service.ReadAllText("")); service.SetRegistryValue("TestKey", "One"); Assert.True(service.TryGetRegistryValue("TestKey", out string result)); Assert.Equal("One", result); }