Skip to content

Commit 44920a4

Browse files
committed
Is not possible to use get_fields because don't exist in django 1.5 and 1.6, then I access the attribute fields in _meta
1 parent a2be77f commit 44920a4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

simple_history/tests/tests/test_models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -311,7 +311,7 @@ def test_model_with_excluded_fields(self):
311311
p = PollWithExcludeFields(question="what's up?", pub_date=today)
312312
p.save()
313313
history = PollWithExcludeFields.history.all()[0]
314-
all_fields_names = [f.name for f in history._meta.get_fields()]
314+
all_fields_names = [f.name for f in history._meta.fields]
315315
self.assertIn('question', all_fields_names)
316316
self.assertNotIn('pub_date', all_fields_names)
317317

0 commit comments

Comments
 (0)