Fix tests
This commit is contained in:
parent
5358752e26
commit
18612e2efc
@ -32,8 +32,7 @@ feature 'Play a hand', type: :feature, js: true do
|
|||||||
# Play the highest card
|
# Play the highest card
|
||||||
@card_to_play = @player.inventory.last
|
@card_to_play = @player.inventory.last
|
||||||
find_card(@card_to_play).click
|
find_card(@card_to_play).click
|
||||||
#click_button 'Play Hand'
|
click_button 'Play Hand'
|
||||||
click_button "play_hand_button_#{@player.id}"
|
|
||||||
|
|
||||||
# No play to beat, because play was invalid
|
# No play to beat, because play was invalid
|
||||||
expect(@game.play_to_beat).to eq(nil)
|
expect(@game.play_to_beat).to eq(nil)
|
||||||
@ -49,9 +48,8 @@ feature 'Play a hand', type: :feature, js: true do
|
|||||||
# Then I see the hand to beat is this play
|
# Then I see the hand to beat is this play
|
||||||
scenario 'first play contains lowest card' do
|
scenario 'first play contains lowest card' do
|
||||||
@card_to_play = @game.lowest_card
|
@card_to_play = @game.lowest_card
|
||||||
find_card(@card_to_play).click
|
find_card(@card_to_play).click(x: 0, y: 0)
|
||||||
#click_button 'Play Hand'
|
click_button 'Play Hand'
|
||||||
click_button "play_hand_button_#{@player.id}"
|
|
||||||
expect(cards_to_beat).to eq @game.lowest_card.to_s
|
expect(cards_to_beat).to eq @game.lowest_card.to_s
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user