inspec/test/functional
Dominik Richter 9e3706aabe bugfix: enforce option values where needed (#1918)
Due to limitations in Thor it is not possible to set an argument to be both optional and its value to be mandatory. E.g. the user supplying the --password argument is optional and not always required, but whenever it is used, it requires a value. Handle options that were defined with mandatory values in a way that fails with an `ArgumentError` if the value is missing, i.e.:

```
> inspec exec examples/profile --password
ArgumentError: Please provide a value for --password. For example: --password=hello.
```

It works without `--password` or with `--password=arg`. Also handled for `--sudo-password`.

Fixes: https://github.com/chef/inspec/issues/1901
As suggested: https://github.com/chef/inspec/pull/1904

Signed-off-by: Dominik Richter <dominik.richter@gmail.com>
2017-06-12 17:33:16 -04:00
..
gitfetcher_test.rb Rename --no-write-lockfile to --no-create-lockfile 2016-09-22 10:08:32 +02:00
helper.rb fix intermitten functional vendor test failures (#1919) 2017-06-12 14:01:26 +02:00
inheritance_test.rb update functional tests 2016-11-04 18:01:28 +01:00
inspec_archive_test.rb Updating tests for profile versions 2016-12-14 16:20:27 +00:00
inspec_artifact_test.rb fix intermitten functional vendor test failures (#1919) 2017-06-12 14:01:26 +02:00
inspec_compliance_test.rb harmonize compliance profiles view with supermarket views (#1654) 2017-04-13 11:24:17 -04:00
inspec_exec_json_test.rb update unit tests 2017-05-31 00:21:05 -05:00
inspec_exec_jsonmin_test.rb bugfix: remove duplicate message in describe.one blocks 2017-06-07 01:27:47 +02:00
inspec_exec_junit_test.rb Replace Nokogiri with REXML in the JUnit formatter 2017-04-03 14:51:48 -04:00
inspec_exec_test.rb bugfix: enforce option values where needed (#1918) 2017-06-12 17:33:16 -04:00
inspec_json_profile_test.rb static keys in all json 2016-09-19 12:00:14 +02:00
inspec_shell_test.rb Update inspec.io references in docs/code 2017-04-27 18:05:51 -04:00
inspec_test.rb Added functional tests for inspec version --format json 2017-05-17 09:41:38 -04:00
inspec_vendor_test.rb fix intermitten functional vendor test failures (#1919) 2017-06-12 14:01:26 +02:00