diff options
| author | LV-426 <lv-426@taproot.org.il> | 2014-10-16 16:01:33 +0200 |
|---|---|---|
| committer | LV-426 <lv-426@taproot.org.il> | 2014-10-16 16:01:33 +0200 |
| commit | d3d8bd18bfbf2da267ea30f5625f092d24b21474 (patch) | |
| tree | 47541e6bbdbff9f36b20c5187eb40ba7dfd832d0 /src-py/test_db_controller.py | |
| parent | dcbc18c61d0917008c09c7a15ec57045641a9bce (diff) | |
DB_row, update DBO_XXX iteration loops, test updates
Diffstat (limited to 'src-py/test_db_controller.py')
| -rw-r--r-- | src-py/test_db_controller.py | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/src-py/test_db_controller.py b/src-py/test_db_controller.py index 66ecfd09..edfd4a22 100644 --- a/src-py/test_db_controller.py +++ b/src-py/test_db_controller.py @@ -135,13 +135,19 @@ class TestDBController(unittest.TestCase): n_set = self.db_ctl.exec_op(op) self.assertEqual(len(n_set), 1) - def test_node_DB_id_lifecycle(self): + def test_load_node_set_by_DB_id(self): """ test node DB id life cycle """ - id_set = self.db_ctl.exec_op(dbc.DBO_add_node_set({'Person': [{'name': 'John Doe', 'id': 'jdoe_00'}, - {'name': 'John Doe', 'id': 'jdoe_01'}]})) - n_set = self.db_ctl.exec_op(dbc.DBO_load_node_set_by_DB_id(id_set)) + + # create nodes, get DB ids + op = dbc.DBO_add_node_set({'T_test_load_node_set_by_DB_id': [{'name': 'John Doe'}, + {'name': 'John Doe'}]}) + id_set = self.db_ctl.exec_op(op) + + # match against DB ids + op = dbc.DBO_load_node_set_by_DB_id(id_set) + n_set = self.db_ctl.exec_op(op) self.assertEqual(len(n_set), len(id_set), 'incorrect result size') def test_partial_query_set_execution_success(self): |
