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
32d34bcf
Kaydet (Commit)
32d34bcf
authored
Nis 26, 2015
tarafından
Gregory P. Smith
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Use assertEqual rather than assertEquals to avoid the deprecation warning.
üst
5d0ccd2f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
test_bytes.py
Lib/test/test_bytes.py
+4
-4
No files found.
Lib/test/test_bytes.py
Dosyayı görüntüle @
32d34bcf
...
@@ -304,10 +304,10 @@ class BaseBytesTest:
...
@@ -304,10 +304,10 @@ class BaseBytesTest:
def
test_hex
(
self
):
def
test_hex
(
self
):
self
.
assertRaises
(
TypeError
,
self
.
type2test
.
hex
)
self
.
assertRaises
(
TypeError
,
self
.
type2test
.
hex
)
self
.
assertRaises
(
TypeError
,
self
.
type2test
.
hex
,
1
)
self
.
assertRaises
(
TypeError
,
self
.
type2test
.
hex
,
1
)
self
.
assertEqual
s
(
self
.
type2test
(
b
""
)
.
hex
(),
""
)
self
.
assertEqual
(
self
.
type2test
(
b
""
)
.
hex
(),
""
)
self
.
assertEqual
s
(
bytearray
([
0x1a
,
0x2b
,
0x30
])
.
hex
(),
'1a2b30'
)
self
.
assertEqual
(
bytearray
([
0x1a
,
0x2b
,
0x30
])
.
hex
(),
'1a2b30'
)
self
.
assertEqual
s
(
self
.
type2test
(
b
"
\x1a\x2b\x30
"
)
.
hex
(),
'1a2b30'
)
self
.
assertEqual
(
self
.
type2test
(
b
"
\x1a\x2b\x30
"
)
.
hex
(),
'1a2b30'
)
self
.
assertEqual
s
(
memoryview
(
b
"
\x1a\x2b\x30
"
)
.
hex
(),
'1a2b30'
)
self
.
assertEqual
(
memoryview
(
b
"
\x1a\x2b\x30
"
)
.
hex
(),
'1a2b30'
)
def
test_join
(
self
):
def
test_join
(
self
):
self
.
assertEqual
(
self
.
type2test
(
b
""
)
.
join
([]),
b
""
)
self
.
assertEqual
(
self
.
type2test
(
b
""
)
.
join
([]),
b
""
)
...
...
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