Open mark0978 opened 6 years ago
Hi!
As a global design choice, we try to avoid any global state for the library — some of the factories could be used as a testing tool for a shared piece of code, and we wouldn't want to impose a specific way of setting up the testing environment to all those projects.
However, there might be some features (either in the SQLAlchemyModelFactory or in SQLAlchemy itself) to handle your case; I think @jeffwidman could help on this — he's the project's SQLAlchemy expert :)
Not quite seeing how to do this without updating the base class of all of my factories. Surely there is an easier way to do this.
https://stackoverflow.com/questions/48568472/how-can-you-globally-set-sqlalchemy-session-persistence-for-factory-boy-in-only