Jaymon / testdata

Python module to make testing easier, it can generate random data like names and text, run commands, fetch urls, create files and directories, and more
MIT License
10 stars 0 forks source link

Autoloading TestData classes #93

Closed Jaymon closed 6 months ago

Jaymon commented 6 months ago

Prom's ModelData falls back to default methods so it never raises the AttributeError needed to autoload. I'm wondering if I should autoload on first call to make sure I've got everything? Autoload only if there are configured prefixes?

I just got stumped on why my method wasn't getting called for like 10 minutes so it would be great to avoid this same issue in the future because I know I'll get confused again.

Jaymon commented 6 months ago

I was thinking about having prom's ModelData class autoload while leaving vanilla testdata the way it is since ModelData does things so differently. Sadly, in order for ModelData to autoload it would need to get loaded, so it's a chicken/egg problem.