/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to tests/test_commands.py

  • Committer: Ian Clatworthy
  • Date: 2009-02-16 15:41:25 UTC
  • mto: (0.64.116 trunk)
  • mto: This revision was merged to the branch mainline in revision 6631.
  • Revision ID: ian.clatworthy@canonical.com-20090216154125-c9cfbw560f6iyilj
get fast-import-filter formatting commands in the output correctly

Show diffs side-by-side

added added

removed removed

Lines of Context:
116
116
            repr(c))
117
117
 
118
118
    def test_commit_with_filecommands(self):
119
 
        file_cmds = [
 
119
        file_cmds = iter([
120
120
            commands.FileDeleteCommand('readme.txt'),
121
121
            commands.FileModifyCommand('NEWS', 'file', False, None,
122
122
                'blah blah blah'),
123
 
            ]
 
123
            ])
124
124
        # user tuple is (name, email, secs-since-epoch, secs-offset-from-utc)
125
125
        committer = ('Joe Wong', 'joe@example.com', 1234567890, -6 * 3600)
126
126
        c = commands.CommitCommand("refs/heads/master", "bbb", None, committer,
185
185
class TestFileModifyDisplay(tests.TestCase):
186
186
 
187
187
    def test_filemodify_file(self):
188
 
        c = commands.FileModifyCommand("foo/bar", "file", False, "23", None)
 
188
        c = commands.FileModifyCommand("foo/bar", "file", False, ":23", None)
189
189
        self.assertEqual("M 644 :23 foo/bar", repr(c))
190
190
 
191
191
    def test_filemodify_file_executable(self):
192
 
        c = commands.FileModifyCommand("foo/bar", "file", True, "23", None)
 
192
        c = commands.FileModifyCommand("foo/bar", "file", True, ":23", None)
193
193
        self.assertEqual("M 755 :23 foo/bar", repr(c))
194
194
 
195
195
    def test_filemodify_file_internal(self):