The Days Are Action-Packed
Running the tests now gives us a different error since weâve defined new_project_path:
â | 1) adding projects allows a user to create a project with tasks |
â | Failure/Error: visit new_project_path |
â | AbstractController::ActionNotFound: |
â | The action 'new' could not be found for ProjectsController |
â | â# ./spec/features/add_project_spec.rb:6:in `block (2 levels) in <top (required)>'â |
We need a new action in our Projects controller. Since it is not going to have logic beyond Rails boilerplate, we donât need to test anything more than the existing Capybara test does.
test_first_rspec/01/gatherer/app/controllers/projects_controller.rb | |
â | âclassâ ProjectsController < ApplicationController |
â | |
â | â ... |
Get Rails 4 Test Prescriptions now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.