diff options
author | Daniel Pyrathon <pirosb3@gmail.com> | 2015-02-10 18:15:54 +0100 |
---|---|---|
committer | Tim Graham <timograham@gmail.com> | 2015-02-10 19:55:06 -0500 |
commit | 19188826b4aa989475418f1ea9bf8631b04da1e8 (patch) | |
tree | 0a005a39819ae21875ea7f6b3eaecb4ece219662 /tests/model_meta | |
parent | 1fbe8a2de334bfec5e9b77e36f8a3c1cf2cd70be (diff) | |
download | django-19188826b4aa989475418f1ea9bf8631b04da1e8.tar.gz |
Fixed #24146 -- Allowed model._meta.get_field() to be used after apps.models_ready
Diffstat (limited to 'tests/model_meta')
-rw-r--r-- | tests/model_meta/tests.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/model_meta/tests.py b/tests/model_meta/tests.py index 4a08b408c6..ef526b7bc4 100644 --- a/tests/model_meta/tests.py +++ b/tests/model_meta/tests.py @@ -178,7 +178,7 @@ class GetFieldByNameTests(OptionsBaseTests): opts = Person._meta # If apps registry is not ready, get_field() searches over only # forward fields. - opts.apps.ready = False + opts.apps.models_ready = False try: # 'data_abstract' is a forward field, and therefore will be found self.assertTrue(opts.get_field('data_abstract')) @@ -191,7 +191,7 @@ class GetFieldByNameTests(OptionsBaseTests): with self.assertRaisesMessage(FieldDoesNotExist, msg): opts.get_field('relating_baseperson') finally: - opts.apps.ready = True + opts.apps.models_ready = True class RelationTreeTests(TestCase): |