/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/test_errors.py

Merge in the BranchBuilder updates, which brings in a newer bzr.dev

Show diffs side-by-side

added added

removed removed

Lines of Context:
30
30
 
31
31
class TestErrors(TestCaseWithTransport):
32
32
 
 
33
    def test_bad_filename_encoding(self):
 
34
        error = errors.BadFilenameEncoding('bad/filen\xe5me', 'UTF-8')
 
35
        self.assertEqualDiff(
 
36
            "Filename 'bad/filen\\xe5me' is not valid in your current"
 
37
            " filesystem encoding UTF-8",
 
38
            str(error))
 
39
 
33
40
    def test_corrupt_dirstate(self):
34
41
        error = errors.CorruptDirstate('path/to/dirstate', 'the reason why')
35
42
        self.assertEqualDiff(
495
502
            "user encoding " + osutils.get_user_encoding(),
496
503
            str(err))
497
504
 
 
505
    def test_unknown_build_action(self):
 
506
        err = errors.UnknownBuildAction('myaction')
 
507
        self.assertEqual("Unknown build action: myaction", str(err))
 
508
 
498
509
    def test_unknown_format(self):
499
510
        err = errors.UnknownFormatError('bar', kind='foo')
500
511
        self.assertEquals("Unknown foo format: 'bar'", str(err))
501
512
 
 
513
    def test_unknown_rules(self):
 
514
        err = errors.UnknownRules(['foo', 'bar'])
 
515
        self.assertEquals("Unknown rules detected: foo, bar.", str(err))
 
516
 
502
517
 
503
518
class PassThroughError(errors.BzrError):
504
519