forked from Github-Mirrors/canaille
Commands does not executed ldap setup and teardown in testing context
This commit is contained in:
parent
23276e60ca
commit
28adc08795
1 changed files with 4 additions and 2 deletions
|
@ -25,6 +25,7 @@ def clean():
|
||||||
teardown_backend,
|
teardown_backend,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
if not current_app.config["TESTING"]:
|
||||||
setup_backend(current_app)
|
setup_backend(current_app)
|
||||||
|
|
||||||
for t in Token.all():
|
for t in Token.all():
|
||||||
|
@ -35,6 +36,7 @@ def clean():
|
||||||
if a.is_expired():
|
if a.is_expired():
|
||||||
a.delete()
|
a.delete()
|
||||||
|
|
||||||
|
if not current_app.config["TESTING"]:
|
||||||
teardown_backend(current_app)
|
teardown_backend(current_app)
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue