Please sign in to comment.
Add blog posts resource route
We add the route, but we don’t just write the simplest code possible to get the test to pass; we “write the code we wish we had.” In this case, we wish we had a resourceful blog posts controller, so we create a resource route, which corresponds to a resourceful controller of the same name.. Rails allows you to "unit test" routes, but for trivial configuration like this, it's fine to let the acceptance test cover it without stepping down to the unit level. Red: uninitialized constant BlogPostsController The next error we get is that that controller doesn’t exist.
- Loading branch information...