X-Git-Url: https://plomlompom.com/repos/berlin_corona.txt?a=blobdiff_plain;f=tests%2Fconditions.py;h=468b1e8b13499ea3c6775baf40f68cad1b646a87;hb=bdb93117ce0f2b08b7b70cf43ac086afa4689c0f;hp=fb55e008bdb316669d1fb8abc56304413cd669d2;hpb=02aa60b59cea2c0401efd785f3bb5d06aec7bf4d;p=plomtask diff --git a/tests/conditions.py b/tests/conditions.py index fb55e00..468b1e8 100644 --- a/tests/conditions.py +++ b/tests/conditions.py @@ -9,7 +9,6 @@ from plomtask.exceptions import HandledException class TestsSansDB(TestCaseSansDB): """Tests requiring no DB setup.""" checked_class = Condition - do_id_test = True versioned_defaults_to_test = {'title': 'UNNAMED', 'description': ''} @@ -19,27 +18,9 @@ class TestsWithDB(TestCaseWithDB): default_init_kwargs = {'is_active': False} test_versioneds = {'title': str, 'description': str} - def test_from_table_row(self) -> None: - """Test .from_table_row() properly reads in class from DB""" - super().test_from_table_row() - self.check_versioned_from_table_row('title', str) - self.check_versioned_from_table_row('description', str) - - def test_Condition_by_id(self) -> None: - """Test .by_id(), including creation.""" - self.check_by_id() - - def test_Condition_all(self) -> None: - """Test .all().""" - self.check_all() - - def test_Condition_versioned_attributes_singularity(self) -> None: - """Test behavior of VersionedAttributes on saving (with .title).""" - self.check_versioned_singularity() - - def test_Condition_remove(self) -> None: + def test_remove(self) -> None: """Test .remove() effects on DB and cache.""" - self.check_remove() + super().test_remove() proc = Process(None) proc.save(self.db_conn) todo = Todo(None, proc, False, '2024-01-01')