Stubhub
Stub an endpoint.
Stubhub helps with developing against an endpoint.
Use stubbed responses to develop against and you will not have to rely on an endpoint
that might be a tad unstable.
Installation
Add this line to your application's Gemfile:
gem 'stub-hub'
And then execute:
$ bundle
Or install it yourself as:
$ gem install stub-hub
Quickstart
Starting the stub server with the seed directory as the current directory:
$ stubhub start
Starting the stub server with a differnt seed directory
$ stubhub start -s "~/path/to/seed/dir"
Stub files
The stub files are matched to the URIs as follows:
uri path | matched file name |
---|
/resource | resource |
/resource.json | resource.json |
/path/to/resource | path-to-resource |
Contributing
- Fork it ( https://github.com/[my-github-username]/stub-hub/fork )
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create a new Pull Request