Clear .todo listener

This commit is contained in:
Annabel Dunstone 2016-03-30 12:28:36 -05:00
parent 0591a7820b
commit f79687ea97
2 changed files with 2 additions and 1 deletions

View file

@ -6,6 +6,7 @@ class @Todos
clearListeners: -> clearListeners: ->
$('.done-todo').off('click') $('.done-todo').off('click')
$('.js-todos-mark-all').off('click') $('.js-todos-mark-all').off('click')
$('.todo').off('click')
initBtnListeners: -> initBtnListeners: ->
$('.done-todo').on('click', @doneClicked) $('.done-todo').on('click', @doneClicked)

View file

@ -89,7 +89,7 @@ class Spinach::Features::DashboardTodos < Spinach::FeatureSteps
end end
step 'I click on the todo' do step 'I click on the todo' do
execute_script("$('.todo:nth-child(1)').click()") find('.todo:nth-child(1)').click
end end
step 'I should be directed to the corresponding page' do step 'I should be directed to the corresponding page' do