Given an author named 'Alan Turing'
When a user visits the authors index page
Then it should show Turing's name and homepage
Hints
Feature: an overview page of all saved authors (index action on AuthorsController), new view (app/views/authors/index.html.erb).
Create a separate file (ending in _spec.rb) for feature tests for this page.
The overview page should contain an HTML table with the headings "Name" and "Homepage", listing the full names as well as homepages of authors and should link to individual author's detail pages. The page should also contain a link to add new authors.
The have_link method might be helpful to test the existence of links:
expect(page).to have_link 'New', href: new_author_path
Here is the relevant section (5.8) of the Rails Guide.
Error
Expected to find text "alan turing" in "authors"
9 exercise tests have passed. There are 44 in total. You will solve multiple at once towards the end.
Scenario
Given an author named 'Alan Turing' When a user visits the authors index page Then it should show Turing's name and homepage
Hints
Feature: an overview page of all saved authors (
index
action on AuthorsController), new view (app/views/authors/index.html.erb
).Create a separate file (ending in
_spec.rb
) for feature tests for this page. The overview page should contain an HTML table with the headings "Name" and "Homepage", listing the full names as well as homepages of authors and should link to individual author's detail pages. The page should also contain a link to add new authors. Thehave_link
method might be helpful to test the existence of links:expect(page).to have_link 'New', href: new_author_path
Here is the relevant section (5.8) of the Rails Guide.
Error
9 exercise tests have passed. There are 44 in total. You will solve multiple at once towards the end.