Add Git overlay, operation tools, and virtualized preview so large folders stay responsive.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -15,13 +15,32 @@ public class UiPreferencesStoreTests
|
||||
"group-network=true",
|
||||
"group-cloud=false",
|
||||
"index-archives=true",
|
||||
"auto-clear-queue=true"
|
||||
"auto-clear-queue=true",
|
||||
"seven-zip=C:\\Program Files\\7-Zip\\7z.exe"
|
||||
]);
|
||||
Assert.Equal("Light", prefs.Theme);
|
||||
Assert.True(prefs.GroupNetworkPlaces);
|
||||
Assert.False(prefs.GroupCloudPlaces);
|
||||
Assert.True(prefs.IndexArchiveContents);
|
||||
Assert.True(prefs.AutoClearQueueWhenDone);
|
||||
Assert.Equal(@"C:\Program Files\7-Zip\7z.exe", prefs.SevenZipPath);
|
||||
Assert.Null(prefs.GitPath);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void Parse_reads_organize_destinations()
|
||||
{
|
||||
var prefs = UiPreferencesStore.Parse(["organize-installers=D:\\Software", "organize-pictures=D:\\Pictures"]);
|
||||
Assert.Equal(@"D:\Software", prefs.OrganizeInstallers);
|
||||
Assert.Equal(@"D:\Pictures", prefs.OrganizePictures);
|
||||
Assert.Null(prefs.OrganizeArchives);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void Parse_reads_git_path()
|
||||
{
|
||||
var prefs = UiPreferencesStore.Parse(["git=C:\\Program Files\\Git\\cmd\\git.exe"]);
|
||||
Assert.Equal(@"C:\Program Files\Git\cmd\git.exe", prefs.GitPath);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
@@ -35,6 +54,8 @@ public class UiPreferencesStoreTests
|
||||
Assert.True(prefs.ShowHiddenFiles);
|
||||
Assert.False(prefs.ShowProtectedSystemLocations);
|
||||
Assert.False(prefs.AutoClearQueueWhenDone);
|
||||
Assert.Null(prefs.SevenZipPath);
|
||||
Assert.Null(prefs.GitPath);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
@@ -105,6 +126,31 @@ public class LocationVisibilityTests
|
||||
Assert.Equal(SizeKnowledge.Unknown, LocationVisibility.ResolveSizeKnowledge(info, true, 0, true));
|
||||
Assert.Equal(SizeKnowledge.Partial, LocationVisibility.ResolveSizeKnowledge(info, true, 1000, true));
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void Recycle_bin_folder_is_never_shown()
|
||||
{
|
||||
var recycle = LocationClassifier.Classify(
|
||||
@"C:\$RECYCLE.BIN", "$RECYCLE.BIN",
|
||||
AttributeFlags.Directory | AttributeFlags.Hidden | AttributeFlags.System, true);
|
||||
Assert.False(LocationVisibility.ShouldShow(recycle, UiPreferences.Default));
|
||||
Assert.False(LocationVisibility.ShouldShow(recycle, UiPreferences.Default with
|
||||
{
|
||||
ShowHiddenFiles = true,
|
||||
ShowProtectedSystemLocations = true
|
||||
}));
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void Recycle_bin_summary_clamps_negative_query_values()
|
||||
{
|
||||
var summary = RecycleBinSummary.FromQuery(-12, -3);
|
||||
Assert.Equal(0, summary.ItemCount);
|
||||
Assert.Equal(0, summary.UsedBytes);
|
||||
var ok = RecycleBinSummary.FromQuery(4096, 3);
|
||||
Assert.Equal(3, ok.ItemCount);
|
||||
Assert.Equal(4096, ok.UsedBytes);
|
||||
}
|
||||
}
|
||||
|
||||
file sealed class PrefsEnv : IAppEnvironment
|
||||
|
||||
Reference in New Issue
Block a user