/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 bzrlib/tests/blackbox/test_ignore.py

  • Committer: Martin Pool
  • Date: 2009-03-13 07:54:48 UTC
  • mfrom: (4144 +trunk)
  • mto: This revision was merged to the branch mainline in revision 4189.
  • Revision ID: mbp@sourcefrog.net-20090313075448-jlz1t7baz7gzipqn
merge trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
47
47
        self.run_bzr_error(('bzr: ERROR: NAME_PATTERN should not '
48
48
                            'be an absolute path\n',),
49
49
                           'ignore /crud')
50
 
        
 
50
 
51
51
    def test_ignore_directories(self):
52
52
        """ignoring a directory should ignore directory tree.
53
53
 
93
93
        self.run_bzr('ignore garh')
94
94
        self.assertEquals(list(tree.unknowns()), [])
95
95
        self.check_file_contents('.bzrignore', '*.blah\ngarh\n')
96
 
       
 
96
 
97
97
    def test_ignore_multiple_arguments(self):
98
98
        """'ignore' works with multiple arguments"""
99
99
        tree = self.make_branch_and_tree('.')
122
122
 
123
123
        # test a single versioned file
124
124
        out, err = self.run_bzr('ignore a')
125
 
        self.assertEqual(out, 
 
125
        self.assertEqual(out,
126
126
                         "Warning: the following files are version controlled"\
127
 
                         " and match your ignore pattern:\na\n")
 
127
                         " and match your ignore pattern:\na\n"\
 
128
                         "These files will continue to be version controlled"\
 
129
                         " unless you 'bzr remove' them.\n")
128
130
 
129
131
        # test a single unversioned file
130
132
        out, err = self.run_bzr('ignore b')
133
135
        # test wildcards
134
136
        tree.add('b')
135
137
        out, err = self.run_bzr('ignore *')
136
 
        self.assertEqual(out, 
 
138
        self.assertEqual(out,
137
139
                         "Warning: the following files are version controlled"\
138
 
                         " and match your ignore pattern:\n.bzrignore\na\nb\n")
 
140
                         " and match your ignore pattern:\n.bzrignore\na\nb\n"\
 
141
                         "These files will continue to be version controlled"\
 
142
                         " unless you 'bzr remove' them.\n")
139
143
 
140
144
    def test_ignored_versioned_file_matching_new_pattern(self):
141
145
        tree = self.make_branch_and_tree('.')
146
150
        # If only the given pattern is used then only 'b' should match in
147
151
        # this case.
148
152
        out, err = self.run_bzr('ignore b')
149
 
        self.assertEqual(out, 
 
153
        self.assertEqual(out,
150
154
                         "Warning: the following files are version controlled"\
151
 
                         " and match your ignore pattern:\nb\n")
 
155
                         " and match your ignore pattern:\nb\n"\
 
156
                         "These files will continue to be version controlled"\
 
157
                         " unless you 'bzr remove' them.\n")