diff --git a/behave/features/request-list.feature b/behave/features/request-list.feature new file mode 100644 index 00000000..74e62e8e --- /dev/null +++ b/behave/features/request-list.feature @@ -0,0 +1,6 @@ +Feature: `osc request list` command + + +Scenario: Run `osc request list` on a project + When I execute osc with args "request list -P test:factory" + Then the exit code is 0 diff --git a/osc/commandline.py b/osc/commandline.py index 304d5394..a594334f 100644 --- a/osc/commandline.py +++ b/osc/commandline.py @@ -2771,9 +2771,10 @@ Please submit there instead, or use --nodevelproject to force direct submission. req_type=opts.type, exclude_projects=opts.exclude_target_project or []) else: roles = ["creator"] if opts.mine else None + types = [opts.type] if opts.type else None results = get_request_collection( apiurl, project=project, package=package, user=who, - states=state_list, types=[opts.type], roles=roles) + states=state_list, types=types, roles=roles) # Check if project actually exists if result list is empty if not results: