/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

Upgraded to the latest 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_disabled_method(self):
 
34
        error = errors.DisabledMethod("class name")
 
35
        self.assertEqualDiff(
 
36
            "The smart server method 'class name' is disabled.", str(error))
 
37
 
33
38
    def test_duplicate_file_id(self):
34
39
        error = errors.DuplicateFileId('a_file_id', 'foo')
35
40
        self.assertEqualDiff('File id {a_file_id} already exists in inventory'
114
119
        error = errors.TooManyConcurrentRequests("a medium")
115
120
        self.assertEqualDiff("The medium 'a medium' has reached its concurrent "
116
121
            "request limit. Be sure to finish_writing and finish_reading on "
117
 
            "the current request that is open.",
 
122
            "the currently open request.",
118
123
            str(error))
119
124
 
120
125
    def test_unknown_hook(self):
228
233
            host='ahost', port=444, msg='Unable to connect to ssh host',
229
234
            orig_error='my_error')
230
235
 
 
236
    def test_unexpected_smart_server_response(self):
 
237
        e = errors.UnexpectedSmartServerResponse(('not yes',))
 
238
        self.assertEqual(
 
239
            "Could not understand response from smart server: ('not yes',)",
 
240
            str(e))
231
241
 
232
242
 
233
243
class PassThroughError(errors.BzrError):