1
0
Fork 0

Fix unit tests due to SQLite master table changes

master
Philip O'Toole 7 years ago
parent fb3cc19680
commit 6d5d4b3d81

@ -1,3 +1,6 @@
## 4.2.2 (unreleased)
- [PR #383](https://github.com/rqlite/rqlite/pull/383): Fix unit tests after underlying SQLite master table changes.
## 4.2.1 (November 10th 2017)
- [PR #367](https://github.com/rqlite/rqlite/pull/367): Remove superflous leading space at CLI prompt.
- [PR #368](https://github.com/rqlite/rqlite/pull/368): CLI displays clear error message when not authorized.

@ -49,7 +49,7 @@ func Test_TableCreation(t *testing.T) {
}
}
func Test_SQLiteMaster(t *testing.T) {
func Test_SQLiteMasterTable(t *testing.T) {
db, path := mustCreateDatabase()
defer db.Close()
defer os.Remove(path)
@ -63,7 +63,7 @@ func Test_SQLiteMaster(t *testing.T) {
if err != nil {
t.Fatalf("failed to query master table: %s", err.Error())
}
if exp, got := `[{"columns":["type","name","tbl_name","rootpage","sql"],"types":["text","text","text","integer","text"],"values":[["table","foo","foo",2,"CREATE TABLE foo (id INTEGER NOT NULL PRIMARY KEY, name TEXT)"]]}]`, asJSON(r); exp != got {
if exp, got := `[{"columns":["type","name","tbl_name","rootpage","sql"],"types":["text","text","text","int","text"],"values":[["table","foo","foo",2,"CREATE TABLE foo (id INTEGER NOT NULL PRIMARY KEY, name TEXT)"]]}]`, asJSON(r); exp != got {
t.Fatalf("unexpected results for query, expected %s, got %s", exp, got)
}
}

Loading…
Cancel
Save