Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/kern/matchbox
Use RSpec and Shoulda matchers in Test::Unit
https://github.com/kern/matchbox
Last synced: 30 days ago
JSON representation
Use RSpec and Shoulda matchers in Test::Unit
- Host: GitHub
- URL: https://github.com/kern/matchbox
- Owner: kern
- License: mit
- Created: 2011-05-09T05:20:19.000Z (over 13 years ago)
- Default Branch: develop
- Last Pushed: 2011-09-19T22:34:21.000Z (about 13 years ago)
- Last Synced: 2024-09-17T19:48:36.787Z (about 2 months ago)
- Language: Ruby
- Homepage: https://github.com/CapnKernul/matchbox
- Size: 97.7 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# matchbox - use RSpec and Shoulda matchers in Test::Unit [![StillMaintained Status](http://stillmaintained.com/CapnKernul/matchbox.png)](http://stillmaintained.com/CapnKernul/matchbox) [![Build Status](http://travis-ci.org/CapnKernul/matchbox.png)](http://travis-ci.org/CapnKernul/matchbox) #
Matchbox allows you to use RSpec and Shoulda matchers as regular, old
`Test::Unit` assertions.## Installation ##
Without bundler:
gem install matchbox
With bundler:
gem 'matchbox'
## Usage ##
Just include the RSpec matchers into the `TestCase` and they can be used as seen
below. This example uses methods found in
[shoulda-matchers](https://github.com/thoughtbot/shoulda-matchers).class PostTest < Test::Unit::TestCase
def test_active_record_relations
post = Post.new
assert_accepts belong_to(:topic), post
end
end## Note on Patches/Pull Requests ##
* Fork the project.
* Make your feature addition or bug fix.
* Add tests for it. This is important so I don't break it in a future version unintentionally.
* Commit, but do not mess with the `Rakefile`. If you want to have your own version, that is fine but bump the version in a commit by itself in another branch so I can ignore it when I pull.
* Send me a pull request. Bonus points for git flow feature branches.## Resources ##
* [GitHub Repository](https://github.com/CapnKernul/matchbox)
* [Documentation](http://rubydoc.info/github/CapnKernul/matchbox)## License ##
Matchbox is licensed under the MIT License. See `LICENSE` for details.