It doesn't makes sense to run if a user has removed all tests from a selected profile, and currently if all tests are removed, then an assertion will be hit in the backend that isn't extremely clear about what went wrong. This should be much easier to understand.
Signed-off-by: Dylan Baker <[email protected]> --- framework/profile.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/framework/profile.py b/framework/profile.py index 4604367e1..ce0b24ce8 100644 --- a/framework/profile.py +++ b/framework/profile.py @@ -389,6 +389,13 @@ def run(profiles, logger, backend, concurrency): profiles = [(p, list(p.itertests())) for p in profiles] log = LogManager(logger, sum(len(l) for _, l in profiles)) + # check that after the filters are run there are actually tests to run + for p, l in profiles: + if not l: + raise exceptions.PiglitUserError( + 'After running filters there are no tests in ' + 'profile "{}"'.format(p.name)) + def test(name, test, profile, this_pool=None): """Function to call test.execute from map""" with backend.write_test(name) as w: -- 2.12.2 _______________________________________________ Piglit mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/piglit
