launchers should support command line options
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Next Generation Checkbox (CLI) |
Fix Released
|
Wishlist
|
Sylvain Pineau |
Bug Description
launchers should support command line options. Since the "command" to execute tests is just a config file that calls an external binary, there should be the ability to pass command line options. For example, canonical-
#!/usr/bin/env checkbox-launcher
[welcome]
text = Welcome to System Certification!
This application will gather information from your system. Then you will be
asked manual tests to confirm that the system is working properly. Finally,
you will be asked for the Secure ID of the computer to submit the
information to the certification.
To learn how to create or locate the Secure ID, please see here:
https:/
[suite]
# Whitelist(s) displayed in the suite selection screen
whitelist_filter = ^((network|
# Whitelist(s) pre-selected in the suite selection screen, default whitelist(s)
whitelist_selection = ^server-full-14.04$
[transport]
submit_to = certification
[config]
config_filename = canonical-
I should be able to override at least some of these via command line options:
-w for a specific whitelist
--config to specify a config
and --non-interactive to skip the welcome, suite and test selection screens as mentioned in another bug.
There should be a hierachy here:
CLI options override launcher file options override config file options override defaults.
Additionally, I should be able to set --secure_id as a commandline option so I can effectively do this:
canonical-
which would automatically re-run the network tests via the network-only whitelist with no user interaction and automatically submit those results to C3 using the secure_id specified.
Related branches
- Zygmunt Krynicki (community): Approve
- Sylvain Pineau (community): Needs Resubmitting
-
Diff: 146 lines (+33/-15)3 files modifiedcheckbox-ng/checkbox_ng/commands/launcher.py (+16/-3)
checkbox-ng/checkbox_ng/commands/newcli.py (+13/-9)
checkbox-ng/checkbox_ng/commands/submit.py (+4/-3)
Changed in checkbox: | |
status: | New → Confirmed |
importance: | Undecided → Wishlist |
affects: | checkbox → checkbox-ng |
Changed in checkbox-ng: | |
assignee: | nobody → Sylvain Pineau (sylvain-pineau) |
status: | Confirmed → In Progress |
Changed in checkbox-ng: | |
status: | In Progress → Fix Committed |
Changed in checkbox-ng: | |
milestone: | none → 0.21 |
Changed in checkbox-ng: | |
milestone: | 0.21 → 0.20 |
tags: | added: cqa-verified |
Changed in checkbox-ng: | |
status: | Fix Committed → Fix Released |
I tested this with a Stella launcher:
./stella-tui -T '2014.com. canonical. ce::stella- wireless' --non-interactive
bypassed the selection screens, selected the stella-wireless test plan, bypassed every user-verify tests and finally provided results locally (xml, html, xlsx, json).
It looks like it works properly!