From 60b5f12f69a6c2537134c8997ee1f24872bf8023 Mon Sep 17 00:00:00 2001 From: ManabuSeki Date: Mon, 7 Mar 2016 21:35:14 +0900 Subject: [PATCH 1/5] Delete signout link --- app/views/members/index.html.haml | 1 - 1 file changed, 1 deletion(-) diff --git a/app/views/members/index.html.haml b/app/views/members/index.html.haml index 3891d91..a9f1e51 100644 --- a/app/views/members/index.html.haml +++ b/app/views/members/index.html.haml @@ -12,7 +12,6 @@ - else = link_to '新しく投票する', new_vote_path -%div= link_to 'サインアウト', signout_path, method: 'delete' %h2 メンバー一覧 From f2669175c3e16d558798ad7f841f7892f2cada72 Mon Sep 17 00:00:00 2001 From: ManabuSeki Date: Mon, 7 Mar 2016 21:36:57 +0900 Subject: [PATCH 2/5] Delete link to vote --- app/views/members/index.html.haml | 7 ------- 1 file changed, 7 deletions(-) diff --git a/app/views/members/index.html.haml b/app/views/members/index.html.haml index a9f1e51..faab36a 100644 --- a/app/views/members/index.html.haml +++ b/app/views/members/index.html.haml @@ -6,13 +6,6 @@ %div= alert -.vote-link - - if current_user.vote - = link_to '投票を編集する', edit_vote_path(current_user.vote) - - else - = link_to '新しく投票する', new_vote_path - - %h2 メンバー一覧 %ul From 0386af82a1db7916a39da54543271b575201c4a4 Mon Sep 17 00:00:00 2001 From: takizawa Date: Mon, 7 Mar 2016 21:46:15 +0900 Subject: [PATCH 3/5] Delete Current User Name --- app/views/members/index.html.haml | 2 -- 1 file changed, 2 deletions(-) diff --git a/app/views/members/index.html.haml b/app/views/members/index.html.haml index faab36a..22d9341 100644 --- a/app/views/members/index.html.haml +++ b/app/views/members/index.html.haml @@ -1,6 +1,4 @@ %h1 よちよち.rb の Ruby Kaja を選ぼう! --# XXX なんか関連がきもちわるいような、、、 -%p 現在、#{current_user.member.nickname} としてサインインしています = image_tag "yochi_rabbit.jpg", alt: "よちよち.rb", width: 500 From 59eaa0404a2aa77cb6d37061b5fc980b8af0067f Mon Sep 17 00:00:00 2001 From: ihorie Date: Wed, 9 Mar 2016 23:55:36 +0900 Subject: [PATCH 4/5] Fix features --- features/step_definitions/common_steps.rb | 4 ++-- features/step_definitions/vote_steps.rb | 2 +- features/top.feature | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/features/step_definitions/common_steps.rb b/features/step_definitions/common_steps.rb index 81ccde0..7458c73 100644 --- a/features/step_definitions/common_steps.rb +++ b/features/step_definitions/common_steps.rb @@ -2,8 +2,8 @@ binding.pry end -ならば(/^"([^"]*)" というリンクが表示されていること$/) do |link| - within '.vote-link' do +ならば(/^ヘッダーに"([^"]*)" というリンクが表示されていること$/) do |link| + within '.navbar-header' do expect(page).to have_link link end end diff --git a/features/step_definitions/vote_steps.rb b/features/step_definitions/vote_steps.rb index 993349d..fa07cfa 100644 --- a/features/step_definitions/vote_steps.rb +++ b/features/step_definitions/vote_steps.rb @@ -1,5 +1,5 @@ もし(/^投票ページを表示する$/) do - within '.vote-link' do + within '.container' do all('a').first.click end end diff --git a/features/top.feature b/features/top.feature index 96a7b0b..f56f38c 100644 --- a/features/top.feature +++ b/features/top.feature @@ -7,7 +7,7 @@ シナリオ: 投票が済んでいるかどうかで表示されるリンクの文言が変わる 前提 GitHub アカウント "alice" でログインしている - ならば "新しく投票する" というリンクが表示されていること + ならば ヘッダーに"投票する" というリンクが表示されていること もし 投票ページを表示する かつ 以下の内容で新規投票する: @@ -17,4 +17,4 @@ もし ホームにアクセスする - ならば "投票を編集する" というリンクが表示されていること + ならば ヘッダーに"編集する" というリンクが表示されていること From ddbe7b8e8cc840b0272b0e67c91183a943b8b833 Mon Sep 17 00:00:00 2001 From: ihorie Date: Thu, 10 Mar 2016 01:19:01 +0900 Subject: [PATCH 5/5] Fix features --- features/step_definitions/common_steps.rb | 6 ++---- features/step_definitions/vote_steps.rb | 4 +--- features/top.feature | 4 ++-- 3 files changed, 5 insertions(+), 9 deletions(-) diff --git a/features/step_definitions/common_steps.rb b/features/step_definitions/common_steps.rb index 7458c73..daf0ecc 100644 --- a/features/step_definitions/common_steps.rb +++ b/features/step_definitions/common_steps.rb @@ -2,10 +2,8 @@ binding.pry end -ならば(/^ヘッダーに"([^"]*)" というリンクが表示されていること$/) do |link| - within '.navbar-header' do - expect(page).to have_link link - end +ならば(/^"([^"]*)" というリンクが表示されていること$/) do |link| + expect(page).to have_link link end もし(/^Kajaeru にアクセスする$/) do diff --git a/features/step_definitions/vote_steps.rb b/features/step_definitions/vote_steps.rb index fa07cfa..8f8a111 100644 --- a/features/step_definitions/vote_steps.rb +++ b/features/step_definitions/vote_steps.rb @@ -1,7 +1,5 @@ もし(/^投票ページを表示する$/) do - within '.container' do - all('a').first.click - end + click_on '投票する' end もし(/^以下の内容で新規投票する:$/) do |table| diff --git a/features/top.feature b/features/top.feature index f56f38c..313447e 100644 --- a/features/top.feature +++ b/features/top.feature @@ -7,7 +7,7 @@ シナリオ: 投票が済んでいるかどうかで表示されるリンクの文言が変わる 前提 GitHub アカウント "alice" でログインしている - ならば ヘッダーに"投票する" というリンクが表示されていること + ならば "投票する" というリンクが表示されていること もし 投票ページを表示する かつ 以下の内容で新規投票する: @@ -17,4 +17,4 @@ もし ホームにアクセスする - ならば ヘッダーに"編集する" というリンクが表示されていること + ならば "編集する" というリンクが表示されていること