コード例 #1
0
ファイル: test_commit.py プロジェクト: Distrotech/bzr
 def test_commit_lossy_foreign(self):
     test_foreign.register_dummy_foreign_for_test(self)
     self.make_branch_and_tree('.',
         format=test_foreign.DummyForeignVcsDirFormat())
     self.run_bzr('commit --lossy --unchanged -m message')
     output = self.run_bzr('revision-info')[0]
     self.assertTrue(output.startswith('1 dummy-'))
コード例 #2
0
 def test_commit_lossy_foreign(self):
     test_foreign.register_dummy_foreign_for_test(self)
     self.make_branch_and_tree(
         '.', format=test_foreign.DummyForeignVcsDirFormat())
     self.run_bzr('commit --lossy --unchanged -m message')
     output = self.run_bzr('revision-info')[0]
     self.assertTrue(output.startswith('1 dummy-'))
コード例 #3
0
ファイル: test_commit.py プロジェクト: Distrotech/bzr
 def test_commit_lossy_foreign(self):
     """Attempt a lossy commit to a foreign branch."""
     test_foreign.register_dummy_foreign_for_test(self)
     wt = self.make_branch_and_tree('.',
         format=test_foreign.DummyForeignVcsDirFormat())
     b = wt.branch
     with file('hello', 'w') as f: f.write('hello world')
     wt.add('hello')
     revid = wt.commit(message='add hello', lossy=True,
         timestamp=1302659388, timezone=0)
     self.assertEquals('dummy-v1:1302659388.0-0-UNKNOWN', revid)
コード例 #4
0
 def test_commit_lossy_foreign(self):
     """Attempt a lossy commit to a foreign branch."""
     test_foreign.register_dummy_foreign_for_test(self)
     wt = self.make_branch_and_tree(
         '.', format=test_foreign.DummyForeignVcsDirFormat())
     b = wt.branch
     with file('hello', 'w') as f:
         f.write('hello world')
     wt.add('hello')
     revid = wt.commit(message='add hello',
                       lossy=True,
                       timestamp=1302659388,
                       timezone=0)
     self.assertEqual('dummy-v1:1302659388.0-0-UNKNOWN', revid)
コード例 #5
0
ファイル: test_commit.py プロジェクト: Distrotech/bzr
 def test_commit_bound_lossy_foreign(self):
     """Attempt a lossy commit to a bzr branch bound to a foreign branch."""
     test_foreign.register_dummy_foreign_for_test(self)
     foreign_branch = self.make_branch('foreign',
         format=test_foreign.DummyForeignVcsDirFormat())
     wt = foreign_branch.create_checkout("local")
     b = wt.branch
     with file('local/hello', 'w') as f: f.write('hello world')
     wt.add('hello')
     revid = wt.commit(message='add hello', lossy=True,
         timestamp=1302659388, timezone=0)
     self.assertEquals('dummy-v1:1302659388.0-0-0', revid)
     self.assertEquals('dummy-v1:1302659388.0-0-0',
         foreign_branch.last_revision())
     self.assertEquals('dummy-v1:1302659388.0-0-0',
         wt.branch.last_revision())
コード例 #6
0
 def test_commit_bound_lossy_foreign(self):
     """Attempt a lossy commit to a bzr branch bound to a foreign branch."""
     test_foreign.register_dummy_foreign_for_test(self)
     foreign_branch = self.make_branch(
         'foreign', format=test_foreign.DummyForeignVcsDirFormat())
     wt = foreign_branch.create_checkout("local")
     b = wt.branch
     with file('local/hello', 'w') as f:
         f.write('hello world')
     wt.add('hello')
     revid = wt.commit(message='add hello',
                       lossy=True,
                       timestamp=1302659388,
                       timezone=0)
     self.assertEqual('dummy-v1:1302659388.0-0-0', revid)
     self.assertEqual('dummy-v1:1302659388.0-0-0',
                      foreign_branch.last_revision())
     self.assertEqual('dummy-v1:1302659388.0-0-0',
                      wt.branch.last_revision())
コード例 #7
0
 def setUp(self):
     super(TestPushForeign, self).setUp()
     test_foreign.register_dummy_foreign_for_test(self)
コード例 #8
0
ファイル: test_push.py プロジェクト: Distrotech/bzr
 def setUp(self):
     super(TestPushForeign, self).setUp()
     test_foreign.register_dummy_foreign_for_test(self)
コード例 #9
0
 def setUp(self):
     test_foreign.register_dummy_foreign_for_test(self)
     # Create an empty branch where we will be able to push
     self.foreign = self.make_branch(
         'to', format=test_foreign.DummyForeignVcsDirFormat())
コード例 #10
0
ファイル: test_dpush.py プロジェクト: GymWenFLL/tpp_libs
 def setUp(self):
     test_foreign.register_dummy_foreign_for_test(self)
     # Create an empty branch where we will be able to push
     self.foreign = self.make_branch("to", format=test_foreign.DummyForeignVcsDirFormat())