diff --git a/lib/capybara/spec/session/node_spec.rb b/lib/capybara/spec/session/node_spec.rb index 10a06408..4054a3c5 100644 --- a/lib/capybara/spec/session/node_spec.rb +++ b/lib/capybara/spec/session/node_spec.rb @@ -242,6 +242,10 @@ Capybara::SpecHelper.spec 'node' do expect(@session.find('//div[@id="hidden_attr"]')).not_to be_visible expect(@session.find('//a[@id="hidden_attr_via_ancestor"]')).not_to be_visible expect(@session.find('//input[@id="hidden_input"]')).not_to be_visible + end + + it 'template elements should not be visible' do + Capybara.ignore_hidden_elements = false expect(@session.find('//template')).not_to be_visible end diff --git a/spec/selenium_spec_ie.rb b/spec/selenium_spec_ie.rb index dc76c878..0ad42396 100644 --- a/spec/selenium_spec_ie.rb +++ b/spec/selenium_spec_ie.rb @@ -112,6 +112,10 @@ Capybara::SpecHelper.run_specs TestSessions::SeleniumIE, 'selenium', capybara_sk skip 'Hangs IE testing for unknown reason' when /drag_to.*HTML5/ pending "IE doesn't support a DataTransfer constuctor" + when /template elements should not be visible/ + skip "IE doesn't support template elements" + when /Element#drop/ + pending "IE doesn't support DataTransfer constructor" end end diff --git a/spec/shared_selenium_session.rb b/spec/shared_selenium_session.rb index d2a7ed0a..a5b306e2 100644 --- a/spec/shared_selenium_session.rb +++ b/spec/shared_selenium_session.rb @@ -421,6 +421,7 @@ RSpec.shared_examples 'Capybara::Session' do |session, mode| describe 'with react' do context 'controlled components' do it 'can set and clear a text field' do + skip "This test doesn't support older browsers" if ie?(session) # session.visit 'https://reactjs.org/docs/forms.html' # session.all(:css, 'h2#controlled-components ~ p a', text: 'Try it on CodePen')[0].click # copied into local view