Skip to content

Commit dd0706f

Browse files
committed
add local testing section to readme
1 parent b6d91f4 commit dd0706f

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

README.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,36 @@ class { 'apache_hardening':
3232
}
3333
```
3434

35+
## Local Testing
36+
37+
For local testing you can use vagrant and Virtualbox of VMWare to run tests locally. You will have to install Virtualbox and Vagrant on your system. See [Vagrant Downloads](http://downloads.vagrantup.com/) for a vagrant package suitable for your system. For all our tests we use `test-kitchen`. If you are not familiar with `test-kitchen` please have a look at [their guide](http://kitchen.ci/docs/getting-started).
38+
39+
Next install test-kitchen:
40+
41+
```bash
42+
# Install dependencies
43+
gem install bundler
44+
bundle install
45+
46+
# Fetch tests
47+
bundle exec thor kitchen:fetch-remote-tests
48+
49+
# Do lint checks
50+
bundle exec rake lint
51+
52+
# Do spec checks
53+
bundle exec rake lint
54+
55+
# fast test on one machine
56+
bundle exec kitchen test default-ubuntu-1204
57+
58+
# for development
59+
bundle exec kitchen create default-ubuntu-1204
60+
bundle exec kitchen converge default-ubuntu-1204
61+
```
62+
63+
For more information see [test-kitchen](http://kitchen.ci/docs/getting-started)
64+
3565
## Contributors + Kudos
3666

3767
* Edmund Haselwanter [ehaselwanter](https://github.com/ehaselwanter)

0 commit comments

Comments
 (0)