Skip to content

Commit

Permalink
Merge pull request #14 from atomic111/master
Browse files Browse the repository at this point in the history
add json format option
  • Loading branch information
arlimus committed Jan 14, 2015
2 parents f09c350 + e3228eb commit be09fff
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,5 +39,5 @@ bundle exec rake serverspec:default target_host=<name-or-ip-of-target-server>
ASK_LOGIN_PASSWORD=true bundle exec rake serverspec:default target_host=192.168.1.222 user=stack
```

add `format=html` to get a report.html document
add `format=html|json` to get a report.html or report.json document

1 change: 1 addition & 0 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ namespace :serverspec do
desc "Run serverspec suite #{suite}"
ServerspecTask.new(suite.to_sym) do |t|
t.rspec_opts = '--no-color --format html --out report.html' if ENV['format'] == 'html'
t.rspec_opts = '--no-color --format json --out report.json' if ENV['format'] == 'json'
t.target = ENV['TARGET_HOST'] || ENV['target_host']
t.ruby_opts = "-I #{suite}/serverspec"
t.pattern = "#{suite}/serverspec/*_spec.rb"
Expand Down

0 comments on commit be09fff

Please sign in to comment.