mirror of
https://gitlab.ub.uni-bielefeld.de/sfb1288inf/nopaque.git
synced 2026-10-11 19:04:24 +00:00
Move cli interface code in package
This commit is contained in:
1 parent
8c935820e8
commit
336bbc39e4
11 files changed
+121
-83
No files matched your search
@@ -0,0 +1,5 @@
|
||||
from flask import Blueprint
|
||||
|
||||
|
||||
bp = Blueprint('tests', __name__)
|
||||
from . import cli
|
||||
@@ -0,0 +1,9 @@
|
||||
from unittest import TestLoader, TextTestRunner
|
||||
from unittest.suite import TestSuite
|
||||
from . import bp
|
||||
|
||||
@bp.cli.command('run')
|
||||
def run_test():
|
||||
''' Run unit tests. '''
|
||||
tests: TestSuite = TestLoader().discover('tests')
|
||||
TextTestRunner(verbosity=2).run(tests)
|
||||
Reference in new issue
Block a user