207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
|
# File 'lib/hiptest-publisher/options_parser.rb', line 207
def self.all_options
[
Option.new('t', 'token=TOKEN', nil, String, "Secret token (available in your project settings)", :token),
Option.new('l', 'language=LANG', 'ruby', String, "Target language", :language),
Option.new('f', 'framework=FRAMEWORK', '', String, "Test framework to use", :framework),
Option.new('o', 'output-directory=PATH', '.', String, "Output directory", :output_directory),
Option.new(nil, 'filename-pattern=PATTERN', nil, String, "Filename pattern (containing %s)", :filename_pattern),
Option.new('c', 'config-file=PATH', nil, String, "Configuration file", :config),
Option.new(nil, 'overriden-templates=PATH', '', String, "Folder for overriden templates", :overriden_templates),
Option.new(nil, 'test-run-id=ID', '', String, "Export data from a test run identified by its id", :test_run_id),
Option.new(nil, 'test-run-name=NAME', '', String, "Export data from a test run identified by its name", :test_run_name),
Option.new(nil, 'only=CATEGORIES', nil, String, "Restrict export to given file categories (--only=list to list them)", :only),
Option.new(nil, 'without=CATEGORIES', nil, String, "Exclude file categories from import (--only=list to list them)", :without),
Option.new('x', 'xml-file=PROJECT_XML', nil, String, "XML file to use instead of fetching it from Hiptest", :xml_file),
Option.new(nil, 'tests-only', false, nil, "(deprecated) alias for --only=tests", :tests_only),
Option.new(nil, 'actionwords-only', false, nil, "(deprecated) alias for --only=actionwords", :actionwords_only),
Option.new(nil, 'actionwords-signature', false, nil, "Export actionwords signature", :actionwords_signature),
Option.new(nil, 'show-actionwords-diff', false, nil, "Show actionwords diff since last update (summary)", :actionwords_diff),
Option.new(nil, 'show-actionwords-diff-as-json', false, nil, "Show actionwords diff since last update (JSON output)", :actionwords_diff_json),
Option.new(nil, 'show-actionwords-deleted', false, nil, "Output signature of deleted action words", :aw_deleted),
Option.new(nil, 'show-actionwords-created', false, nil, "Output code for new action words", :aw_created),
Option.new(nil, 'show-actionwords-renamed', false, nil, "Output signatures of renamed action words", :aw_renamed),
Option.new(nil, 'show-actionwords-signature-changed', false, nil, "Output signatures of action words for which signature changed", :aw_signature_changed),
Option.new(nil, 'show-actionwords-definition-changed', false, nil, "Output action words for which definition changed", :aw_definition_changed),
Option.new(nil, 'library-name=LIBRARY_NAME', nil, String, "Use in conjunction with show-actionwords-*: show the diff for the specified library", :library_name),
Option.new(nil, 'with-folders', false, nil, "Use folders hierarchy to export files in respective directories", :with_folders),
Option.new(nil, 'empty-folders', false, nil, "Export empty folders", :empty_folders),
Option.new(nil, 'split-scenarios', false, nil, "Export each scenario in a single file (except for Gherkin based languages)", :split_scenarios),
Option.new(nil, 'leafless-export', false, nil, "Use only last level action word", :leafless_export),
Option.new('s', 'site=SITE', 'https://app.hiptest.com', String, "Site to fetch from", :site),
Option.new('p', 'push=FILE.TAP', '', String, "Push a results file to the server", :push),
Option.new(nil, 'global-failure-on-missing-reports', false, nil, "When there is no results file to push, report a global failure", :global_failure_on_missing_reports),
Option.new(nil, 'push-format=tap', 'tap', String, "Format of the test results (cucumber-json, junit, nunit, robot, tap)", :push_format),
Option.new(nil, 'sort=[id,order,alpha]', 'order', String, "Sorting of tests in output: id will sort them by age, order will keep the same order than in hiptest (only with --with-folders option, will fallback to id otherwise), alpha will sort them by name", :sort),
Option.new(nil, '[no-]uids', true, nil, 'Export UIDs (note: can be disabled only for Gherkin-based exports, may cause issue when pushing results back)', :uids),
Option.new(nil, 'parameter-delimiter', '"', String, 'Parameter delimiter (for Gherkin based export only)', :parameter_delimiter),
Option.new(nil, 'with-dataset-names', false, nil, 'Export dataset name when creating feature files (note: available only for Gherkin-based exports)', :with_dataset_names),
Option.new(nil, 'keep-filenames', false, nil, "Keep the same name as in Hiptest for the test files (note: may cause encoding issues)", :keep_filenames),
Option.new(nil, 'keep-foldernames', false, nil, "Keep the same name as in Hiptest for the folders (note: may cause encoding issues)", :keep_foldernames),
Option.new(nil, 'filter-on-scenario-ids=IDS', '', String, "Filter on scenario ids (use commas to separate ids when fetching multiple scenarios)", :filter_on_scenario_ids),
Option.new(nil, 'filter-on-folder-ids=IDS', '', String, "Filter on folder ids (use commas to separate ids when fetching multiple folders)", :filter_on_folder_ids),
Option.new(nil, 'filter-on-scenario-name=NAME', '', String, "Filter on scenario name (only one name is accepted)", :filter_on_scenario_name),
Option.new(nil, 'filter-on-folder-name=NAME', '', String, "Filter on folder name (only one name is accepted)", :filter_on_folder_name),
Option.new(nil, 'filter-on-tags=TAGS', '', String, "Filter on scenarios and folder tags (use commas to separate tags when using multiple tags)", :filter_on_tags),
Option.new(nil, 'filter-on-status=STATUS', '', String, "Filter on test status in last build (use in conjunction with a test run)", :filter_on_status),
Option.new(nil, 'not-recursive', false, nil, "Used in conjunction with filter-on-folder-ids or filter-on-folder-name: only exports those folders, not their children", :not_recursive),
Option.new(nil, 'check-version', false, nil, "Check if a new release of hiptest-publisher is available", :check_version),
Option.new(nil, 'force', false, nil, "Force overwrite of existing files (do not apply to test files)", :force_overwrite),
Option.new('v', 'verbose', false, nil, "Run verbosely", :verbose)
]
end
|