Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
c90be30b
Commit
c90be30b
authored
Dec 28, 2012
by
Serhiy Storchaka
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Issue #16792: Use assertIs() to test identity.
parent
8876145f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
Lib/test/test_int.py
Lib/test/test_int.py
+4
-4
No files found.
Lib/test/test_int.py
View file @
c90be30b
...
...
@@ -380,11 +380,11 @@ class IntTestCases(IntLongCommonTests, unittest.TestCase):
@
test_support
.
cpython_only
def
test_small_ints
(
self
):
self
.
assert
True
(
int
(
'10'
)
is
10
)
self
.
assert
True
(
int
(
'-1'
)
is
-
1
)
self
.
assert
Is
(
int
(
'10'
),
10
)
self
.
assert
Is
(
int
(
'-1'
),
-
1
)
if
have_unicode
:
self
.
assert
True
(
int
(
u'10'
)
is
10
)
self
.
assert
True
(
int
(
u'-1'
)
is
-
1
)
self
.
assert
Is
(
int
(
u'10'
),
10
)
self
.
assert
Is
(
int
(
u'-1'
),
-
1
)
def
test_intconversion
(
self
):
# Test __int__()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment