def test_cleanup(self): self.assertTrue(CleanupAddon.can_install(self.component, None)) rev = self.component.repository.last_revision addon = CleanupAddon.create(self.component) addon.post_update(self.component, "da07dc0dc7052dc44eadfa8f3a2f2609ec634303") self.assertNotEqual(rev, self.component.repository.last_revision) commit = self.component.repository.show(self.component.repository.last_revision) self.assertIn("csv-mono/cs.csv", commit)
def test_cleanup(self): self.assertTrue(CleanupAddon.is_compatible(self.subproject)) addon = CleanupAddon.create(self.subproject) rev = self.subproject.repository.last_revision addon.post_update(self.subproject, '') self.assertNotEqual(rev, self.subproject.repository.last_revision) commit = self.subproject.repository.show( self.subproject.repository.last_revision) self.assertIn('json-mono-sync/cs.json', commit)
def test_cleanup(self): self.assertTrue(CleanupAddon.is_compatible(self.subproject)) addon = CleanupAddon.create(self.subproject) rev = self.subproject.repository.last_revision addon.post_update(self.subproject, '') self.assertNotEqual(rev, self.subproject.repository.last_revision) commit = self.subproject.repository.show( self.subproject.repository.last_revision) self.assertIn('android-not-synced/values-cs/strings.xml', commit)
def test_cleanup(self): self.assertTrue(CleanupAddon.can_install(self.component, None)) addon = CleanupAddon.create(self.component) rev = self.component.repository.last_revision addon.post_update(self.component, '') self.assertNotEqual(rev, self.component.repository.last_revision) commit = self.component.repository.show( self.component.repository.last_revision) self.assertIn('json-mono-sync/cs.json', commit)
def test_cleanup(self): self.assertTrue(CleanupAddon.can_install(self.component, None)) addon = CleanupAddon.create(self.component) rev = self.component.repository.last_revision addon.post_update(self.component, '') self.assertNotEqual(rev, self.component.repository.last_revision) commit = self.component.repository.show( self.component.repository.last_revision) self.assertIn('android-not-synced/values-cs/strings.xml', commit)
def test_cleanup(self): self.assertTrue(CleanupAddon.is_compatible(self.subproject)) addon = CleanupAddon.create(self.subproject) rev = self.subproject.repository.last_revision addon.post_update(self.subproject, 'da07dc0dc7052dc44eadfa8f3a2f2609ec634303') self.assertNotEqual(rev, self.subproject.repository.last_revision) commit = self.subproject.repository.show( self.subproject.repository.last_revision) self.assertIn('resx/cs.resx', commit)
def test_cleanup(self): self.assertTrue(CleanupAddon.can_install(self.component, None)) addon = CleanupAddon.create(self.component) rev = self.component.repository.last_revision addon.post_update(self.component, '') self.assertNotEqual(rev, self.component.repository.last_revision) commit = self.component.repository.show( self.component.repository.last_revision ) self.assertIn('json-mono-sync/cs.json', commit)
def test_cleanup(self): self.assertTrue(CleanupAddon.can_install(self.component, None)) addon = CleanupAddon.create(self.component) rev = self.component.repository.last_revision addon.post_update(self.component, '') self.assertNotEqual(rev, self.component.repository.last_revision) commit = self.component.repository.show( self.component.repository.last_revision ) self.assertIn('android-not-synced/values-cs/strings.xml', commit)
def test_cleanup(self): self.assertTrue(CleanupAddon.can_install(self.component, None)) rev = self.component.repository.last_revision addon = CleanupAddon.create(self.component) self.assertNotEqual(rev, self.component.repository.last_revision) rev = self.component.repository.last_revision addon.post_update(self.component, "", False) self.assertEqual(rev, self.component.repository.last_revision) addon.post_update(self.component, "", False) commit = self.component.repository.show(self.component.repository.last_revision) self.assertIn("cs/changelogs/100000.txt", commit)
def test_cleanup(self): self.assertTrue(CleanupAddon.can_install(self.component, None)) rev = self.component.repository.last_revision addon = CleanupAddon.create(self.component) # Unshallow the local repo with self.component.repository.lock: self.component.repository.execute(["fetch", "--unshallow", "origin"]) addon.post_update(self.component, "da07dc0dc7052dc44eadfa8f3a2f2609ec634303") self.assertNotEqual(rev, self.component.repository.last_revision) commit = self.component.repository.show(self.component.repository.last_revision) self.assertIn("resx/cs.resx", commit)
def test_cleanup(self): self.assertTrue(CleanupAddon.can_install(self.component, None)) rev = self.component.repository.last_revision addon = CleanupAddon.create(self.component) self.assertNotEqual(rev, self.component.repository.last_revision) rev = self.component.repository.last_revision addon.post_update(self.component, "", False) self.assertEqual(rev, self.component.repository.last_revision) addon.post_update(self.component, "", False) commit = self.component.repository.show(self.component.repository.last_revision) self.assertIn("winrc/cs-CZ.rc", commit) self.assertIn("\n-IDS_MSG5", commit)
def test_cleanup(self): self.assertTrue(CleanupAddon.can_install(self.component, None)) rev = self.component.repository.last_revision addon = CleanupAddon.create(self.component) self.assertNotEqual(rev, self.component.repository.last_revision) rev = self.component.repository.last_revision addon.post_update(self.component, "", False) self.assertEqual(rev, self.component.repository.last_revision) addon.post_update(self.component, "", False) commit = self.component.repository.show(self.component.repository.last_revision) self.assertIn("android-not-synced/values-cs/strings.xml", commit) self.assertIn('\n- <string name="hello">Ahoj svete</string>', commit)
def test_cleanup(self): self.assertTrue(CleanupAddon.can_install(self.component, None)) addon = CleanupAddon.create(self.component) rev = self.component.repository.last_revision addon.post_update( self.component, 'da07dc0dc7052dc44eadfa8f3a2f2609ec634303' ) self.assertNotEqual(rev, self.component.repository.last_revision) commit = self.component.repository.show( self.component.repository.last_revision ) self.assertIn('resx/cs.resx', commit)
def test_cleanup(self): self.assertTrue(CleanupAddon.can_install(self.component, None)) rev = self.component.repository.last_revision addon = CleanupAddon.create(self.component) self.assertNotEqual(rev, self.component.repository.last_revision) rev = self.component.repository.last_revision addon.post_update(self.component, "", False) self.assertEqual(rev, self.component.repository.last_revision) addon.post_update(self.component, "", False) commit = self.component.repository.show(self.component.repository.last_revision) # It should remove string not present in the English file self.assertIn("intermediate/cs.json", commit) self.assertIn('- "orangutan"', commit)
def test_cleanup(self): self.assertTrue(CleanupAddon.can_install(self.component, None)) rev = self.component.repository.last_revision addon = CleanupAddon.create(self.component) self.assertNotEqual(rev, self.component.repository.last_revision) rev = self.component.repository.last_revision addon.post_update(self.component, '') self.assertEqual(rev, self.component.repository.last_revision) addon.post_update(self.component, '') commit = self.component.repository.show( self.component.repository.last_revision ) self.assertIn('cs/changelogs/100000.txt', commit)
def test_cleanup(self): self.assertTrue(CleanupAddon.can_install(self.component, None)) init_rev = self.component.repository.last_revision addon = CleanupAddon.create(self.component) self.assertNotEqual(init_rev, self.component.repository.last_revision) rev = self.component.repository.last_revision addon.post_update(self.component, "", False) self.assertEqual(rev, self.component.repository.last_revision) addon.post_update(self.component, "", False) commit = self.component.repository.show(self.component.repository.last_revision) self.assertIn("java/swing_messages_cs.properties", commit) self.component.do_reset() self.edit_unit("Hello, world!\n", "Nazdar svete!\n") self.get_translation().commit_pending("test", None) self.assertNotEqual(init_rev, self.component.repository.last_revision) commit = self.component.repository.show(self.component.repository.last_revision) self.assertIn("java/swing_messages_cs.properties", commit) self.assertIn("-state=Stale", commit)