Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
D
django
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
django
Commits
c9088cfc
Kaydet (Commit)
c9088cfc
authored
Tem 09, 2018
tarafından
Sergey Fedoseev
Kaydeden (comit)
Tim Graham
Tem 09, 2018
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Fixed some assertTrue() that were intended to be assertEqual().
üst
3411c555
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
6 deletions
+6
-6
tests.py
tests/model_inheritance/tests.py
+2
-2
tests.py
tests/queries/tests.py
+3
-3
test_encoding.py
tests/utils_tests/test_encoding.py
+1
-1
No files found.
tests/model_inheritance/tests.py
Dosyayı görüntüle @
c9088cfc
...
...
@@ -461,8 +461,8 @@ class InheritanceSameModelNameTests(SimpleTestCase):
ForeignReferent
=
Referent
self
.
assertFalse
(
hasattr
(
Referenced
,
related_name
))
self
.
assert
True
(
Referenced
.
model_inheritance_referent_references
.
rel
.
model
,
LocalReferent
)
self
.
assert
True
(
Referenced
.
tests_referent_references
.
rel
.
model
,
ForeignReferent
)
self
.
assert
Is
(
Referenced
.
model_inheritance_referent_references
.
field
.
model
,
LocalReferent
)
self
.
assert
Is
(
Referenced
.
tests_referent_references
.
field
.
model
,
ForeignReferent
)
class
InheritanceUniqueTests
(
TestCase
):
...
...
tests/queries/tests.py
Dosyayı görüntüle @
c9088cfc
...
...
@@ -93,8 +93,8 @@ class Queries1Tests(TestCase):
self
.
assertEqual
(
qs4
.
query
.
subq_aliases
,
{
'T'
,
'U'
,
'V'
})
# It is possible to reuse U for the second subquery, no need to use W.
self
.
assertNotIn
(
'w0'
,
str
(
qs4
.
query
)
.
lower
())
# So, 'U0."id"' is referenced twice.
self
.
assert
True
(
str
(
qs4
.
query
)
.
lower
()
.
count
(
'u0'
),
2
)
# So, 'U0."id"' is referenced
in SELECT and WHERE
twice.
self
.
assert
Equal
(
str
(
qs4
.
query
)
.
lower
()
.
count
(
'u0.'
),
4
)
def
test_ticket1050
(
self
):
self
.
assertQuerysetEqual
(
...
...
@@ -511,7 +511,7 @@ class Queries1Tests(TestCase):
# This is also a good select_related() test because there are multiple
# Note entries in the SQL. The two Note items should be different.
self
.
assert
True
(
repr
(
qs
[
0
]
.
note
),
'<Note: n2>'
)
self
.
assert
Equal
(
repr
(
qs
[
0
]
.
note
),
'<Note: n2>'
)
self
.
assertEqual
(
repr
(
qs
[
0
]
.
creator
.
extra
.
note
),
'<Note: n1>'
)
def
test_ticket3037
(
self
):
...
...
tests/utils_tests/test_encoding.py
Dosyayı görüntüle @
c9088cfc
...
...
@@ -28,7 +28,7 @@ class TestEncodingUtils(SimpleTestCase):
def
test_force_text_lazy
(
self
):
s
=
SimpleLazyObject
(
lambda
:
'x'
)
self
.
assert
True
(
type
(
force_text
(
s
)),
str
)
self
.
assert
Is
(
type
(
force_text
(
s
)),
str
)
def
test_force_text_DjangoUnicodeDecodeError
(
self
):
msg
=
(
...
...
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