Skip to content

Commit

Permalink
Only run tests when the db can update conflicts.
Browse files Browse the repository at this point in the history
  • Loading branch information
tim-schilling committed Nov 19, 2024
1 parent ed10665 commit 1286a72
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion simple_history/tests/tests/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,13 @@
import django
from django.contrib.auth import get_user_model
from django.db import IntegrityError, transaction
from django.test import TestCase, TransactionTestCase, override_settings, tag
from django.test import (
TestCase,
TransactionTestCase,
override_settings,
skipUnlessDBFeature,
tag,
)
from django.utils import timezone

from simple_history.exceptions import AlternativeManagerError, NotHistoricalModelError
Expand Down Expand Up @@ -258,6 +264,7 @@ def test_bulk_create_history_with_duplicates_ignore_conflicts(self):
self.assertEqual(PollWithUniqueQuestion.objects.count(), 2)
self.assertEqual(PollWithUniqueQuestion.history.count(), 2)

@skipUnlessDBFeature("supports_update_conflicts")
def test_bulk_create_history_with_duplicates_update_conflicts_create_only_field(
self,
):
Expand Down

0 comments on commit 1286a72

Please sign in to comment.