Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
…istory

# Conflicts:
#	simple_history/tests/models.py
#	simple_history/tests/tests/test_utils.py
  • Loading branch information
NoelJames committed Sep 25, 2023
2 parents eed2f52 + 30db4d2 commit dd40ec4
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions simple_history/tests/tests/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -516,15 +516,15 @@ class CustomHistoricalAttrsTest(TestCase):

def setUp(self):
self.data = [
PollWithHistoricalSessionAttr(id=x, question='Question ' + str(x))
PollWithHistoricalSessionAttr(id=x, question="Question " + str(x))
for x in range(5)
]

def test_bulk_create_history_with_custom_model_attributes(self):

bulk_create_with_history(
self.data, PollWithHistoricalSessionAttr,
custom_historical_attrs={'session': 'jam'}
custom_historical_attrs={"session": "jam"}
)

self.assertEqual(PollWithHistoricalSessionAttr.objects.count(), 5)
Expand All @@ -535,15 +535,15 @@ def test_bulk_create_history_with_custom_model_attributes(self):

def test_bulk_update_history_with_custom_model_attributes(self):
update_data = [
PollWithHistoricalSessionAttr(id=x, question='Q' + str(x))
PollWithHistoricalSessionAttr(id=x, question="Q" + str(x))
for x in range(5)
]

bulk_update_with_history(
update_data,
PollWithHistoricalSessionAttr,
fields=["question"],
custom_historical_attrs={'session': 'training'}
custom_historical_attrs={"session": "training"}
)

self.assertTrue(
Expand All @@ -559,7 +559,7 @@ def test_bulk_manager_with_custom_model_attributes(self):
history_manager = get_history_manager_for_model(PollWithHistoricalSessionAttr)
history_manager.bulk_history_create(
[],
custom_historical_attrs={'session': 'co-op'}
custom_historical_attrs={"session": "co-op"}
)

self.assertTrue(
Expand Down

0 comments on commit dd40ec4

Please sign in to comment.