diff --git a/system_test/e2e/helpers.py b/system_test/e2e/helpers.py index 6f179e8c..af37cd4c 100644 --- a/system_test/e2e/helpers.py +++ b/system_test/e2e/helpers.py @@ -262,6 +262,11 @@ class Node(object): raise_for_status(r) return r.json() + def pragmas(self): + r = requests.get(self._status_url()) + raise_for_status(r) + return r.json()['store']['sqlite3']['pragmas'] + def nodes(self): r = requests.get(self._nodes_url()) raise_for_status(r) diff --git a/system_test/e2e/single_node.py b/system_test/e2e/single_node.py index 2860f31d..676e0d5d 100644 --- a/system_test/e2e/single_node.py +++ b/system_test/e2e/single_node.py @@ -25,6 +25,11 @@ class TestSingleNode(unittest.TestCase): def tearDown(self): self.cluster.deprovision() + def test_pragmas(self): + '''Test that the pragma configration is correct''' + n = self.cluster.wait_for_leader() + self.assertEqual(n.pragmas(), d_("{'ro':{'foreign_keys':'0','journal_mode':'wal','synchronous':'0','wal_autocheckpoint':'1000'},'rw':{'foreign_keys':'0','journal_mode':'wal','synchronous':'0','wal_autocheckpoint':'0'}}")) + def test_simple_raw_queries(self): '''Test simple queries work as expected''' n = self.cluster.wait_for_leader()