Sha256: c02ad829a48c4b0d5307709a1dce073f10acd4bd43b043278372a6f17f59ee3f
Contents?: true
Size: 1.45 KB
Versions: 1
Compression:
Stored size: 1.45 KB
Contents
# RSpec::WebserviceMatchers This [gem](https://rubygems.org/gems/rspec-webservice_matchers) enables you to black-box test a web app's server configuration. For example, whether its SSL certificate is correctly configured and not expired. It's a tool for doing **Test Driven Devops**. (I just made that up.) This library takes a very minimalist approach: by simply adding new RSpec matchers, you can use your own RSpec writing style; no new DSL to learn. Installation ------------ ```Shell $ gem install rspec-webservice_matchers ``` What You Get ------------ These new RSpec matchers: * `be_status` * `have_a_valid_cert` * `enforce_https_everywhere` (See [EFF](https://www.eff.org/https-everywhere)) * `redirect_permanently_to` Example ------- ```Ruby require 'rspec/webservice_matchers' describe 'My app' do context 'www.myapp.com' do it { should be_status 200 } it { should have_a_valid_cert } end it 'redirects to www' do expect('http://myapp.com').to redirect_permanently_to 'http://www.myapp.com/' end it 'forces visitors to use https' do expect('myapp.com').to enforce_https_everywhere end end ``` TODO ---- * Matchers for more high-level cases, such as the two kinds of temp. redirect * Matchers for JSON schema * More matchers refactored from [weblaws.org](http://www.weblaws.org/) code Related Projects ---------------- * [serverspec](http://serverspec.org) * [HTTP Assertions](https://github.com/dogweather/HTTP-Assertions)
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
rspec-webservice_matchers-0.2.0 | README.md |