mirror of
https://github.com/inspec/inspec
synced 2024-11-10 07:04:15 +00:00
document OR feature
This commit is contained in:
parent
baaaf3c95b
commit
8bb791c12f
1 changed files with 20 additions and 1 deletions
21
README.md
21
README.md
|
@ -170,6 +170,25 @@ Also have a look at our examples for:
|
||||||
- [Using InSpec with Test Kitchen & Ansible](https://github.com/chef/inspec/tree/master/examples/kitchen-ansible)
|
- [Using InSpec with Test Kitchen & Ansible](https://github.com/chef/inspec/tree/master/examples/kitchen-ansible)
|
||||||
- [Implementing an InSpec profile](https://github.com/chef/inspec/tree/master/examples/profile)
|
- [Implementing an InSpec profile](https://github.com/chef/inspec/tree/master/examples/profile)
|
||||||
|
|
||||||
|
## Or tests: Testing for a OR b
|
||||||
|
|
||||||
|
* Using describe.one, you can test for a or b. The control will be marked as passing if EITHER condition is met.
|
||||||
|
|
||||||
|
```ruby
|
||||||
|
control 'or-test' do
|
||||||
|
impact 1.0
|
||||||
|
title 'This is a OR test'
|
||||||
|
describe.one do
|
||||||
|
describe ssh_config do
|
||||||
|
its('Protocol') { should eq('3') }
|
||||||
|
end
|
||||||
|
describe ssh_config do
|
||||||
|
its('Protocol') { should eq('2') }
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
```
|
||||||
|
|
||||||
## Command Line Usage
|
## Command Line Usage
|
||||||
|
|
||||||
### exec
|
### exec
|
||||||
|
@ -231,7 +250,7 @@ OpenSUSE | 13.1/13.2/42.1 | x86_64
|
||||||
OmniOS | | x86_64
|
OmniOS | | x86_64
|
||||||
Gentoo Linux | | x86_64
|
Gentoo Linux | | x86_64
|
||||||
Arch Linux | | x86_64
|
Arch Linux | | x86_64
|
||||||
HP-UX | 11.31 | ia64
|
HP-UX | 11.31 | ia64
|
||||||
|
|
||||||
* For Windows 2008 and 2008 R2 an updated Powershell (Windows Management Framework 5.0) is required.
|
* For Windows 2008 and 2008 R2 an updated Powershell (Windows Management Framework 5.0) is required.
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue