As of v3.2.0 FactoryBoy has finally fixed the issue w/ generate requiring a "locale" parameter via PR 828.
We can therefore stop pinning FactoryBoy!
Some of the existing calls to generate scattered throughout our apps' unit tests should be refactored to use the "Faker" library rather than "FactoryBoy's" wrapper of "Faker". That will happen as django-astrosat-core is propagated to those apps.
But the new version of FactoryBoy had broken how I had been using factory.Maybe. This PR addresses that by refactoring optional_declaration to make the "decider" of factory.Maybe a lazy function (which, again, uses "Faker" rather than "FactoryBoy's" wrapper).
As of v3.2.0 FactoryBoy has finally fixed the issue w/
generate
requiring a "locale" parameter via PR 828.We can therefore stop pinning FactoryBoy!
Some of the existing calls to
generate
scattered throughout our apps' unit tests should be refactored to use the "Faker" library rather than "FactoryBoy's" wrapper of "Faker". That will happen as django-astrosat-core is propagated to those apps.But the new version of FactoryBoy had broken how I had been using
factory.Maybe
. This PR addresses that by refactoringoptional_declaration
to make the "decider" offactory.Maybe
a lazy function (which, again, uses "Faker" rather than "FactoryBoy's" wrapper).