Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
8e79e6e5
Unverified
Kaydet (Commit)
8e79e6e5
authored
Şub 19, 2019
tarafından
Serhiy Storchaka
Kaydeden (comit)
GitHub
Şub 19, 2019
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Fix syntax warnings in tests introduced in bpo-15248. (GH-11932)
üst
e7a4bb55
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
6 deletions
+10
-6
test_bytes.py
Lib/test/test_bytes.py
+5
-3
test_extcall.py
Lib/test/test_extcall.py
+3
-2
test_tuple.py
Lib/test/test_tuple.py
+2
-1
No files found.
Lib/test/test_bytes.py
Dosyayı görüntüle @
8e79e6e5
...
...
@@ -852,9 +852,10 @@ class BytesTest(BaseBytesTest, unittest.TestCase):
type2test
=
bytes
def
test_getitem_error
(
self
):
b
=
b
'python'
msg
=
"byte indices must be integers or slices"
with
self
.
assertRaisesRegex
(
TypeError
,
msg
):
b
'python'
[
'a'
]
b
[
'a'
]
def
test_buffer_is_readonly
(
self
):
fd
=
os
.
open
(
__file__
,
os
.
O_RDONLY
)
...
...
@@ -1042,14 +1043,15 @@ class ByteArrayTest(BaseBytesTest, unittest.TestCase):
type2test
=
bytearray
def
test_getitem_error
(
self
):
b
=
bytearray
(
b
'python'
)
msg
=
"bytearray indices must be integers or slices"
with
self
.
assertRaisesRegex
(
TypeError
,
msg
):
b
ytearray
(
b
'python'
)
[
'a'
]
b
[
'a'
]
def
test_setitem_error
(
self
):
b
=
bytearray
(
b
'python'
)
msg
=
"bytearray indices must be integers or slices"
with
self
.
assertRaisesRegex
(
TypeError
,
msg
):
b
=
bytearray
(
b
'python'
)
b
[
'a'
]
=
"python"
def
test_nohash
(
self
):
...
...
Lib/test/test_extcall.py
Dosyayı görüntüle @
8e79e6e5
...
...
@@ -264,7 +264,8 @@ What about willful misconduct?
...
TypeError: dir() argument after * must be an iterable, not function
>>> None(*h)
>>> nothing = None
>>> nothing(*h)
Traceback (most recent call last):
...
TypeError: NoneType object argument after * must be an iterable,
\
...
...
@@ -305,7 +306,7 @@ not function
...
TypeError: dir() argument after ** must be a mapping, not function
>>>
None
(**h)
>>>
nothing
(**h)
Traceback (most recent call last):
...
TypeError: NoneType object argument after ** must be a mapping,
\
...
...
Lib/test/test_tuple.py
Dosyayı görüntüle @
8e79e6e5
...
...
@@ -19,9 +19,10 @@ class TupleTest(seq_tests.CommonTest):
type2test
=
tuple
def
test_getitem_error
(
self
):
t
=
()
msg
=
"tuple indices must be integers or slices"
with
self
.
assertRaisesRegex
(
TypeError
,
msg
):
()
[
'a'
]
t
[
'a'
]
def
test_constructors
(
self
):
super
()
.
test_constructors
()
...
...
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