lib/model: Add folders on start in model (#6135)

This commit is contained in:
Simon Frei
2019-11-08 10:56:16 +01:00
committed by GitHub
parent f15a1528fc
commit bee7cce081
8 changed files with 54 additions and 61 deletions

View File

@@ -54,7 +54,7 @@ func TestRecvOnlyRevertDeletes(t *testing.T) {
// Start the folder. This will cause a scan, should discover the other stuff in the folder
m.StartFolder("ro")
m.startFolder("ro")
m.ScanFolder("ro")
// We should now have two files and two directories.
@@ -125,7 +125,7 @@ func TestRecvOnlyRevertNeeds(t *testing.T) {
// Start the folder. This will cause a scan.
m.StartFolder("ro")
m.startFolder("ro")
m.ScanFolder("ro")
// Everything should be in sync.
@@ -221,7 +221,7 @@ func TestRecvOnlyUndoChanges(t *testing.T) {
// Start the folder. This will cause a scan.
m.StartFolder("ro")
m.startFolder("ro")
m.ScanFolder("ro")
// Everything should be in sync.
@@ -317,7 +317,7 @@ func setupROFolder() (*model, *sendOnlyFolder) {
w.SetFolder(fcfg)
m := newModel(w, myID, "syncthing", "dev", db.OpenMemory(), nil)
m.AddFolder(fcfg)
m.addFolder(fcfg)
f := &sendOnlyFolder{
folder: folder{