forked from twisted/twisted
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'trunk' into 9192-dmollerm-reverse_proxy_resource_docstring
- Loading branch information
Showing
8 changed files
with
73 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
# Copyright (c) Twisted Matrix Laboratories. | ||
# See LICENSE for details. | ||
|
||
""" | ||
Tests for L{twisted.internet.error} | ||
""" | ||
|
||
from __future__ import division, absolute_import | ||
|
||
from twisted.trial.unittest import SynchronousTestCase | ||
from twisted.internet import error | ||
|
||
|
||
|
||
class ConnectionAbortedTests(SynchronousTestCase): | ||
""" | ||
Tests for the L{twisted.internet.error.ConnectionAborted} exception. | ||
""" | ||
def test_str(self): | ||
""" | ||
The default message of L{ConnectionAborted} is a sentence which points | ||
to L{ITCPTransport.abortConnection()} | ||
""" | ||
self.assertEqual( | ||
("Connection was aborted locally" | ||
" using ITCPTransport.abortConnection."), | ||
str(error.ConnectionAborted()), | ||
) | ||
|
||
|
||
def test_strArgs(self): | ||
""" | ||
Any arguments passed to L{ConnectionAborted} are included in its | ||
message. | ||
""" | ||
self.assertEqual( | ||
("Connection was aborted locally using" | ||
" ITCPTransport.abortConnection:" | ||
" foo bar."), | ||
str(error.ConnectionAborted('foo', 'bar')), | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Improved the exception text for mutually exclusive function arguments. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
The errback example in the docstring of twisted.logger.Logger.failure has been corrected. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
The message of twisted.internet.error.ConnectionAborted is no longer truncated. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters