def test_is_synced(self): article = Article("Test", "lk", datetime.now(), uuid.uuid4()) article.save_to_db() article.set_title("TestUpdated") article.sync_to_db() self.assertTrue(article.is_synced(), "article marked un-synced when it is") article.remove_from_db()
def test_not_synced(self): article = Article("Test", "lk", datetime.now(), uuid.uuid4()) article.save_to_db() article.set_title("TestUpdated") self.assertFalse(article.is_synced(),"article marked synced when it is not") article.remove_from_db()