diff options
author | BonfaceKilz | 2021-04-29 21:57:16 +0300 |
---|---|---|
committer | GitHub | 2021-04-29 21:57:16 +0300 |
commit | 4c8c5390bdba594c217d7ca0114a80a6b3634e24 (patch) | |
tree | b48693555b97fd21e37b263591685af75a2a4b45 /wqflask/tests/unit/base/test_data_set.py | |
parent | bab514be0f0d01fc192638b8e7ccd5909b842b23 (diff) | |
parent | 881090ff15a5a563bccefcbd08d373c88a64aa31 (diff) | |
download | genenetwork2-4c8c5390bdba594c217d7ca0114a80a6b3634e24.tar.gz |
Merge pull request #566 from BonfaceKilz/Feature/Add-upload-data-forms
Chore/Cosmetic-changes
Diffstat (limited to 'wqflask/tests/unit/base/test_data_set.py')
-rw-r--r-- | wqflask/tests/unit/base/test_data_set.py | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/wqflask/tests/unit/base/test_data_set.py b/wqflask/tests/unit/base/test_data_set.py index 96563a16..ee5d6f06 100644 --- a/wqflask/tests/unit/base/test_data_set.py +++ b/wqflask/tests/unit/base/test_data_set.py @@ -31,14 +31,12 @@ class TestDataSetTypes(unittest.TestCase): def tearDown(self): self.app_context.pop() - @mock.patch('base.data_set.g') - def test_data_set_type(self, db_mock): + def test_data_set_type(self): """Test that DatasetType returns correctly if the Redis Instance is not empty and the name variable exists in the dictionary """ with app.app_context(): - db_mock.get = mock.Mock() redis_mock = mock.Mock() redis_mock.get.return_value = self.test_dataset self.assertEqual(DatasetType(redis_mock) @@ -89,8 +87,7 @@ class TestDataSetTypes(unittest.TestCase): '"B139_K_1206_M": "ProbeSet", ' '"B139_K_1206_R": "ProbeSet", ' '"Test": "ProbeSet"}')) - - db_mock.db.execute.assert_called_with( + db_mock.db.execute.assert_called_once_with( ("SELECT ProbeSetFreeze.Id FROM ProbeSetFreeze " + "WHERE ProbeSetFreeze.Name = \"Test\" ") ) |