20

In the Java space, JUnit is predominately used and in .NET I believe nUnit is very popular. Is a community agreed upon unit testing framework for the Ruby world?

Background: I ask because I am new to Ruby and want to practice TDD at same time as I learn Ruby. So far I've only played with Test::Unit.

4 Answers 4

14

You can stick to Test::Unit or you can have nice extensions to it using Shoulda or some cool contexts using Context.

On the other side, if you prefer BDD then you can safely stick to RSpec.

As for for acceptance testing use Cucumber .

Sign up to request clarification or add additional context in comments.

1 Comment

MiniTest is also becoming a very popular option which combines both Unit and Spec testing styles into one library.
7

See also What’s the most commonly used unit testing framework for different types of Ruby applications? question.

Comments

1

The most popular one is RSpec, although both expectations and test/unit are quite well-known.

Comments

1

You may want to look into the manager gem that I have developed. It not only is a test framework, but is does documentation as well at the same time.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.