lib, gui: Default ignores for new folders (fixes #7428) (#7530)

This commit is contained in:
Simon Frei
2022-01-13 23:38:21 +01:00
committed by GitHub
parent 40bb52fdd8
commit 21d04b895a
17 changed files with 718 additions and 218 deletions
+3 -3
View File
@@ -1515,7 +1515,7 @@ func TestIgnores(t *testing.T) {
t.Error("No error")
}
// Invalid path, marker should be missing, hence returns an error.
// Invalid path, treated like no patterns at all.
fcfg := config.FolderConfiguration{ID: "fresh", Path: "XXX"}
ignores := ignore.New(fcfg.Filesystem(), ignore.WithCache(m.cfg.Options().CacheIgnoredFiles))
m.fmut.Lock()
@@ -1524,8 +1524,8 @@ func TestIgnores(t *testing.T) {
m.fmut.Unlock()
_, _, err = m.LoadIgnores("fresh")
if err == nil {
t.Error("No error")
if err != nil {
t.Error("Got error for inexistent folder path")
}
// Repeat tests with paused folder