Refactored integration tests

Added internal/rc to remote control a Syncthing process and made the
"awaiting sync" determination reliable.
This commit is contained in:
Jakob Borg
2015-06-18 15:22:45 +02:00
parent 69af77a3bd
commit c3d07d60ca
19 changed files with 868 additions and 1142 deletions

View File

@@ -29,16 +29,9 @@ func TestStressHTTP(t *testing.T) {
}
log.Println("Starting up...")
sender := syncthingProcess{ // id1
instance: "2",
argv: []string{"-home", "h2"},
port: 8082,
apiKey: apiKey,
}
err = sender.start()
if err != nil {
t.Fatal(err)
}
p := startInstance(t, 2)
defer checkedStop(t, p)
// Create a client with reasonable timeouts on all stages of the request.
@@ -147,9 +140,4 @@ func TestStressHTTP(t *testing.T) {
if firstError != nil {
t.Error(firstError)
}
_, err = sender.stop()
if err != nil {
t.Error(err)
}
}