1
0
Fork 0
mirror of https://github.com/teamcapybara/capybara.git synced 2022-11-09 12:08:07 -05:00

Spelling fixes

This commit is contained in:
Thomas Walpole 2022-09-22 22:26:44 -07:00
parent 3c8f494bac
commit f37e50ee7e
8 changed files with 14 additions and 12 deletions

View file

@ -830,7 +830,7 @@ Release date: 2018-03-23
### Changed
* Visibile text whitespace is no longer fully normalized in favor of being more in line with the WebDriver spec for visible text
* Visible text whitespace is no longer fully normalized in favor of being more in line with the WebDriver spec for visible text
* Drivers are expected to close extra windows when resetting the session
* Selenium driver supports Date/Time when filling in date/time/datetime-local inputs
* `current_url` returns the url for the top level browsing context
@ -1236,7 +1236,7 @@ Release date: 2016-01-27
# Version 2.6.0
Relase date: 2016-01-17
Release date: 2016-01-17
### Fixed
@ -1300,7 +1300,7 @@ Release date: 2014-10-13
# Version 2.4.3
Relase date: 2014-09-21
Release date: 2014-09-21
### Fixed

View file

@ -570,7 +570,9 @@ module Capybara
when :visible
node.initial_cache[:visible] || (node.initial_cache[:visible].nil? && node.visible?)
when :hidden
(node.initial_cache[:visible] == false) || (node.initial_cache[:visbile].nil? && !node.visible?)
# TODO: check why the 'visbile' cache spelling mistake wasn't caught in a test
# (node.initial_cache[:visible] == false) || (node.initial_cache[:visbile].nil? && !node.visible?)
(node.initial_cache[:visible] == false) || (node.initial_cache[:visible].nil? && !node.visible?)
else
true
end

View file

@ -203,7 +203,7 @@ module Capybara
##
#
# Set the default visibility mode that shouble be used if no visibile option is passed when using the selector.
# Set the default visibility mode that should be used if no visible option is passed when using the selector.
# If not specified will default to the behavior indicated by Capybara.ignore_hidden_elements
#
# @param [Symbol] default_visibility Only find elements with the specified visibility:

View file

@ -39,8 +39,8 @@ Capybara::SpecHelper.spec '#have_no_ancestor' do
it 'should assert no matching ancestor' do
el = @session.find(:css, '#ancestor1')
expect(el).to have_no_ancestor(:css, '#child')
expect(el).to have_no_ancestor(:css, '#ancestor1_sibiling')
expect(el).to have_no_ancestor(:css, '#ancestor1_sibling')
expect(el).not_to have_ancestor(:css, '#child')
expect(el).not_to have_ancestor(:css, '#ancestor1_sibiling')
expect(el).not_to have_ancestor(:css, '#ancestor1_sibling')
end
end

View file

@ -88,7 +88,7 @@ banana</textarea>
</div>
<div style="display: none;">
<a id="first_invisble" class="hidden">first hidden link</a>
<a id="first_invisible" class="hidden">first hidden link</a>
</div>
<div style="display: none;">
@ -138,7 +138,7 @@ banana</textarea>
Ancestor
<div id="child">Child</div>
</div>
<div id="ancestor1_sibiling">
<div id="ancestor1_sibling">
ASibling
</div>
</div>

View file

@ -111,7 +111,7 @@ RSpec.describe Capybara do
end
describe 'adding a selector' do
it 'can set default visiblity' do
it 'can set default visibility' do
described_class.add_selector :hidden_field do
visible :hidden
css { |_sel| 'input[type="hidden"]' }

View file

@ -68,7 +68,7 @@ Capybara::SpecHelper.run_specs TestSessions::SeleniumFirefox, 'selenium', capyba
when 'Capybara::Session selenium #reset_session! removes ALL cookies'
pending "Geckodriver doesn't provide a way to remove cookies outside the current domain"
when /drag_to.*HTML5/
pending "Firefox < 62 doesn't support a DataTransfer constuctor" if firefox_lt?(62.0, @session)
pending "Firefox < 62 doesn't support a DataTransfer constructor" if firefox_lt?(62.0, @session)
when 'Capybara::Session selenium #accept_alert should handle the alert if the page changes',
'Capybara::Session selenium #accept_alert with an asynchronous alert should accept the alert'
skip 'No clue what Firefox is doing here - works fine on MacOS locally'

View file

@ -103,7 +103,7 @@ Capybara::SpecHelper.run_specs TestSessions::SeleniumIE, 'selenium', capybara_sk
when /#attach_file with a block/
skip 'Hangs IE testing for unknown reason'
when /drag_to.*HTML5/
pending "IE doesn't support a DataTransfer constuctor"
pending "IE doesn't support a DataTransfer constructor"
when /template elements should not be visible/
skip "IE doesn't support template elements"
when /Element#drop/