April 2016
Intermediate to advanced
222 pages
4h 30m
English
In this chapter, we learned about RSpec's mocks, which let us change how specific parts of our code behave during tests. We also learned about hooks, which we used to set up and tear down state for our test cases. Using these tools, we learned how to test complex stateful behavior in our application code, which we also adjusted to increase testability.
Read now
Unlock full access