diff options
| author | sage <laymonage@gmail.com> | 2020-12-09 21:45:18 +0700 |
|---|---|---|
| committer | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2020-12-11 11:18:15 +0100 |
| commit | a891e1bb0a3e1b29a461784cd0bf717513e72f19 (patch) | |
| tree | bb1f15167c8e90a56b1bfebfa740df0e51bb6faf /tests | |
| parent | ce7f8c2eada40950796cb20c88c36f568052f070 (diff) | |
[3.1.x] Fixed #32252 -- Fixed __isnull=True on key transforms on SQLite and Oracle.
__isnull=True on key transforms should not match keys with NULL values.
Backport of 8d7085e0fd004af5431389f3d903aba6220d7957 from master
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/model_fields/test_jsonfield.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/model_fields/test_jsonfield.py b/tests/model_fields/test_jsonfield.py index f041c659d1..a4bc9e2454 100644 --- a/tests/model_fields/test_jsonfield.py +++ b/tests/model_fields/test_jsonfield.py @@ -535,6 +535,10 @@ class TestQuerying(TestCase): self.objs[:3] + self.objs[5:], ) self.assertSequenceEqual( + NullableJSONModel.objects.filter(value__j__isnull=True), + self.objs[:4] + self.objs[5:], + ) + self.assertSequenceEqual( NullableJSONModel.objects.filter(value__a__isnull=False), [self.objs[3], self.objs[4]], ) |
