test: Clean & unflake cli & conflict tests

This commit is contained in:
Jakob Borg 2017-11-13 01:06:16 +01:00
parent 6e35592e9e
commit 80031c59da
2 changed files with 11 additions and 2 deletions

View File

@ -17,7 +17,7 @@ import (
)
func TestCLIReset(t *testing.T) {
dirs := []string{"h1/index-v0.11.0.db"}
dirs := []string{"h1/index-v0.14.0.db"}
// Create directories that reset will remove
@ -30,7 +30,7 @@ func TestCLIReset(t *testing.T) {
// Run reset to clean up
cmd := exec.Command("../bin/syncthing", "-no-browser", "-home", "h1", "-reset")
cmd := exec.Command("../bin/syncthing", "-no-browser", "-home", "h1", "-reset-database")
cmd.Stdout = os.Stdout
cmd.Stderr = os.Stdout
err := cmd.Run()

View File

@ -56,6 +56,9 @@ func TestConflictsDefault(t *testing.T) {
receiver := startInstance(t, 2)
defer checkedStop(t, receiver)
sender.ResumeAll()
receiver.ResumeAll()
// Rescan with a delay on the next one, so we are not surprised by a
// sudden rescan while we're trying to introduce conflicts.
@ -242,6 +245,9 @@ func TestConflictsInitialMerge(t *testing.T) {
receiver := startInstance(t, 2)
defer checkedStop(t, receiver)
sender.ResumeAll()
receiver.ResumeAll()
log.Println("Syncing...")
rc.AwaitSync("default", sender, receiver)
@ -320,6 +326,9 @@ func TestConflictsIndexReset(t *testing.T) {
receiver := startInstance(t, 2)
defer checkedStop(t, receiver)
sender.ResumeAll()
receiver.ResumeAll()
log.Println("Syncing...")
rc.AwaitSync("default", sender, receiver)