More use of cluster.Credentials
@@ -30,7 +30,7 @@ func Test_StoreClientSideBySide(t *testing.T) {
if exp, got := "[{}]", asJSON(res); exp != got {
t.Fatalf("unexpected results, expt %s, got %s", exp, got)
}
- res, err = client.Execute(executeRequestFromString("CREATE TABLE bar (id INTEGER NOT NULL PRIMARY KEY, name TEXT)"), leaderAddr, "", "", shortWait)
+ res, err = client.Execute(executeRequestFromString("CREATE TABLE bar (id INTEGER NOT NULL PRIMARY KEY, name TEXT)"), leaderAddr, nil, shortWait)
if err != nil {
t.Fatalf("failed to execute via remote: %s", err.Error())
}
@@ -45,7 +45,7 @@ func Test_StoreClientSideBySide(t *testing.T) {
if exp, got := `[{"last_insert_id":1,"rows_affected":1}]`, asJSON(res); exp != got {
t.Fatalf("unexpected results, expt %s, got %s", exp, got)
}
- res, err = client.Execute(executeRequestFromString(`INSERT INTO bar(name) VALUES("fiona")`), leaderAddr, "", "", shortWait)
+ res, err = client.Execute(executeRequestFromString(`INSERT INTO bar(name) VALUES("fiona")`), leaderAddr, nil, shortWait)
if err != nil {
t.Fatalf("failed to execute via remote: %s", err.Error())
}
@@ -68,14 +68,14 @@ func Test_StoreClientSideBySide(t *testing.T) {
t.Fatalf("unexpected results, expt %s, got %s", exp, got)
}
- rows, err = client.Query(queryRequestFromString(`SELECT * FROM foo`), leaderAddr, "", "", shortWait)
+ rows, err = client.Query(queryRequestFromString(`SELECT * FROM foo`), leaderAddr, nil, shortWait)
if err != nil {
t.Fatalf("failed to query via remote: %s", err.Error())
}
if exp, got := `[{"columns":["id","name"],"types":["integer","text"],"values":[[1,"fiona"]]}]`, asJSON(rows); exp != got {
t.Fatalf("unexpected results, expt %s, got %s", exp, got)
}
- rows, err = client.Query(queryRequestFromString(`SELECT * FROM bar`), leaderAddr, "", "", shortWait)
+ rows, err = client.Query(queryRequestFromString(`SELECT * FROM bar`), leaderAddr, nil, shortWait)
if err != nil {
t.Fatalf("failed to query via remote: %s", err.Error())
}
@@ -90,7 +90,7 @@ func Test_StoreClientSideBySide(t *testing.T) {
if exp, got := `[{"error":"no such table: qux"}]`, asJSON(rows); exp != got {
t.Fatalf("unexpected results, expt %s, got %s", exp, got)
}
- rows, err = client.Query(queryRequestFromString(`SELECT * FROM qux`), leaderAddr, "", "", shortWait)
+ rows, err = client.Query(queryRequestFromString(`SELECT * FROM qux`), leaderAddr, nil, shortWait)
if err != nil {
t.Fatalf("failed to query via remote: %s", err.Error())
}
