Change always passing visible false tests.
Created by: cirosantilli
Many usages of visible: false
are wrong since visible: false
matches both visible and invisible elements: http://rubydoc.info/github/jnicklas/capybara/master/Capybara/Node/Finders#all-instance_method
The correct way to check that an element is present but not visible is:
expect(find(...)).not_to be_visible
The two "I can't preview without text" scenarios are not true anymore: now you can preview without text, so I removed then. They only passed because of the misuse. Screenshot:
'I should see add a diff comment button'
is simply wrong: it should be visible: true
instead of visible: false
.