italomaia/flask-empty

Implements tests in blueprints

cnicodeme opened this issue · 1 comments

Hi! Great bootstrap project :)

How you handle the tests is interesting, and I think it could go a bit further :

When calling test from the manage.py, it should lookup in the tests folder in the root app, but also in each registered blueprints.

In that way, each blueprint would have it's own set of tests.

I'd like to submit a pull for this kind of idea but I don't know how to loop over blueprints in the test case.

Well, "right now" there is no good way to iterate through blueprints. If you take a look at main.py, the way blueprints are loaded is a little frail and functions are not aware of which blueprints are loaded and how to interact with them (like load specific blueprint features...).
Aaaanyway, I'll see to this blueprint awarenes structural issue.