Skip to content

Commit

Permalink
fix: expected query count django 4.2 (#33235)
Browse files Browse the repository at this point in the history
  • Loading branch information
irtazaakram authored Sep 13, 2023
1 parent 933485d commit 4191a37
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Test batch_get_or_create in ExternalId model
"""

import django
from django.test import TransactionTestCase
from common.djangoapps.student.tests.factories import UserFactory
from openedx.core.djangoapps.external_user_ids.models import ExternalId
Expand All @@ -19,7 +20,7 @@ class TestBatchGenerateExternalIds(TransactionTestCase):
# 3 - Get external ids that already exists
# 4 - BEGIN (from bulk_create)
# 5 - Create new external ids
EXPECTED_NUM_OF_QUERIES = 5
EXPECTED_NUM_OF_QUERIES = 5 if django.VERSION < (4, 2) else 6

def test_batch_get_or_create_user_ids(self):
"""
Expand Down

0 comments on commit 4191a37

Please sign in to comment.