Search⌘ K
AI Features

Let's Write Some Rails

Explore how to implement test-driven development by writing end-to-end and unit tests for a Rails project using Capybara. Understand how to move logic out of controllers and views to create faster, more maintainable tests, and learn to write tests that guide new code development through clear requirements.

Previous chapter

In the previous chapter, we created some basic functionality for a project-management application using test-driven development.

In this chapter

In this chapter, we’ll augment the model testing by testing the entire Rails stack’s logic from request to response using end-to-end tests. To do this, we’ll use a tool called ...