diff options
author | Matthew Lemon <lemon@matthewlemon.com> | 2020-09-03 17:25:30 +0100 |
---|---|---|
committer | Matthew Lemon <lemon@matthewlemon.com> | 2020-09-03 17:25:30 +0100 |
commit | 959c001905fffc4840e8f795170d724474bc1997 (patch) | |
tree | b9fec38599e7afbe0dfd832d397b68cf4082c1be /ctrack/caf/tests/factories.py | |
parent | 0d0066bdc03fcafa660db7b002ec2bb5846dc4fd (diff) |
factory boy to 3.0.1
Diffstat (limited to '')
-rw-r--r-- | ctrack/caf/tests/factories.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/ctrack/caf/tests/factories.py b/ctrack/caf/tests/factories.py index 7aaf716..f186290 100644 --- a/ctrack/caf/tests/factories.py +++ b/ctrack/caf/tests/factories.py @@ -7,7 +7,7 @@ from ctrack.caf.models import ApplicableSystem, Grading, DocumentFile, FileStore from ctrack.organisations.tests.factories import OrganisationFactory, PersonFactory -class CAFFactory(factory.DjangoModelFactory): +class CAFFactory(factory.django.DjangoModelFactory): quality_grading = factory.SubFactory("ctrack.caf.tests.factories.GradingFactory") confidence_grading = factory.SubFactory("ctrack.caf.tests.factories.GradingFactory") organisation = factory.SubFactory("ctrack.organisations.tests.OrganisationFactory") @@ -23,7 +23,7 @@ class CAFFactory(factory.DjangoModelFactory): model = CAF -class ApplicableSystemFactory(factory.DjangoModelFactory): +class ApplicableSystemFactory(factory.django.DjangoModelFactory): """Factory for Essential Services.""" name = Faker("text", max_nb_chars=100, ext_word_list=None) @@ -36,7 +36,7 @@ class ApplicableSystemFactory(factory.DjangoModelFactory): model = ApplicableSystem -class GradingFactory(factory.DjangoModelFactory): +class GradingFactory(factory.django.DjangoModelFactory): descriptor = factory.Iterator( ["Q1", "Q2", "Q3", "Q4", "Q5", "C1", "C2", "C3", "C4", "C5"] ) @@ -47,7 +47,7 @@ class GradingFactory(factory.DjangoModelFactory): model = Grading -class FileStoreFactory(factory.DjangoModelFactory): +class FileStoreFactory(factory.django.DjangoModelFactory): descriptor = "File Store X" virtual_location = Faker("street_name") physical_location = random.choice(["Cupboard A", "Tin Box", "The Vault"]) @@ -57,7 +57,7 @@ class FileStoreFactory(factory.DjangoModelFactory): model = FileStore -class DocumentFileFactory(factory.DjangoModelFactory): +class DocumentFileFactory(factory.django.DjangoModelFactory): name = Faker("file_name", extension="xlsx") type = random.choice([1, 2, 3, 4]) file_store_location = factory.SubFactory(FileStoreFactory) |