mirror of
https://github.com/django/django.git
synced 2025-10-31 09:41:08 +00:00
Fixed #34840 -- Avoided casting string base fields on PostgreSQL.
Thanks Alex Vandiver for the report.
Regression in 09ffc5c121.
This commit is contained in:
@@ -1337,6 +1337,16 @@ class LookupTests(TestCase):
|
||||
with self.assertRaisesMessage(ValueError, msg):
|
||||
qs.exists()
|
||||
|
||||
def test_isnull_textfield(self):
|
||||
self.assertSequenceEqual(
|
||||
Author.objects.filter(bio__isnull=True),
|
||||
[self.au2],
|
||||
)
|
||||
self.assertSequenceEqual(
|
||||
Author.objects.filter(bio__isnull=False),
|
||||
[self.au1],
|
||||
)
|
||||
|
||||
def test_lookup_rhs(self):
|
||||
product = Product.objects.create(name="GME", qty_target=5000)
|
||||
stock_1 = Stock.objects.create(product=product, short=True, qty_available=180)
|
||||
|
||||
Reference in New Issue
Block a user