In the previous chapter, you learned how to write expectations to check your code’s behavior. You got to know the various parts of an expectation, such as the subject and the matcher.
Now, it’s time to take a closer look at matchers. You’ve called them in your specs and combined them with other matchers. You’ve even written a simple one from scratch, though most of the time you won’t have to. RSpec ships with a ton of useful matchers to help you specify exactly how you want your code to behave.
In this chapter, we’re going to take a tour of RSpec’s ...