mirror of
https://github.com/python/cpython.git
synced 2025-11-26 21:33:10 +00:00
Fix str.rpartition(sep) when sep is not found in str.
Partially from SF patch #1551339, but also taken from head.
This commit is contained in:
parent
8dc71f2161
commit
29a5fdb7ca
6 changed files with 14 additions and 11 deletions
|
|
@ -1069,7 +1069,7 @@ class MixinStrUnicodeUserStringTest:
|
|||
# from raymond's original specification
|
||||
S = 'http://www.python.org'
|
||||
self.checkequal(('http', '://', 'www.python.org'), S, 'rpartition', '://')
|
||||
self.checkequal(('http://www.python.org', '', ''), S, 'rpartition', '?')
|
||||
self.checkequal(('', '', 'http://www.python.org'), S, 'rpartition', '?')
|
||||
self.checkequal(('', 'http://', 'www.python.org'), S, 'rpartition', 'http://')
|
||||
self.checkequal(('http://www.python.', 'org', ''), S, 'rpartition', 'org')
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue