|
46 | 46 | scenario "index" do |
47 | 47 | visit toc_index_path |
48 | 48 |
|
| 49 | + expect(page.title).to eq("Table of Contents - The Journal of Open Source Software") |
| 50 | + |
49 | 51 | within("#toc-header") do |
50 | 52 | expect(page).to have_content("Table of Contents") |
51 | 53 | expect(page).to_not have_link("Table of Contents") |
|
64 | 66 |
|
65 | 67 | scenario "by year" do |
66 | 68 | visit toc_year_path(year: @years.first) |
| 69 | + |
| 70 | + expect(page.title).to eq("#{@years.first} - The Journal of Open Source Software") |
| 71 | + |
67 | 72 | within("#toc-header") do |
68 | 73 | expect(page).to have_content("Year #{@years.first}") |
69 | 74 | expect(page).to have_link("Table of Contents") |
|
84 | 89 |
|
85 | 90 | scenario "by volume" do |
86 | 91 | visit toc_volume_path(volume: 1) |
| 92 | + |
| 93 | + expect(page.title).to eq("Volume 1 - The Journal of Open Source Software") |
| 94 | + |
87 | 95 | within("#toc-header") do |
88 | 96 | expect(page).to have_content("Year #{@years.first}") |
89 | 97 | expect(page).to have_content("Volume 1") |
|
94 | 102 | expect(page).to_not have_link(@last_accepted_paper.title) |
95 | 103 |
|
96 | 104 | visit toc_volume_path(volume: @volumes.last) |
| 105 | + |
| 106 | + expect(page.title).to eq("Volume #{@volumes.last} - The Journal of Open Source Software") |
| 107 | + |
97 | 108 | within("#toc-header") do |
98 | 109 | expect(page).to have_content("Year #{@years.last}") |
99 | 110 | expect(page).to have_content("Volume #{@volumes.last}") |
|
106 | 117 |
|
107 | 118 | scenario "by issue" do |
108 | 119 | visit toc_issue_path(issue: 1) |
| 120 | + |
| 121 | + expect(page.title).to eq("Issue 1 - The Journal of Open Source Software") |
| 122 | + |
109 | 123 | within("#toc-header") do |
110 | 124 | expect(page).to have_content("#{Date::MONTHNAMES[@launch_month]} #{@years.first} Volume 1") |
111 | 125 | expect(page).to have_content("Issue 1") |
|
116 | 130 | expect(page).to_not have_link(@last_accepted_paper.title) |
117 | 131 |
|
118 | 132 | visit toc_issue_path(issue: @issues.last) |
| 133 | + |
| 134 | + expect(page.title).to eq("Issue #{@issues.last} - The Journal of Open Source Software") |
| 135 | + |
119 | 136 | within("#toc-header") do |
120 | 137 | expect(page).to have_content("#{Date::MONTHNAMES[@now.month]} #{@years.last} Volume #{@volumes.last}") |
121 | 138 | expect(page).to have_content("Issue #{@issues.last}") |
|
0 commit comments