diff --git a/rb/spec/integration/selenium/webdriver/app_cache_spec.rb b/rb/spec/integration/selenium/webdriver/app_cache_spec.rb deleted file mode 100644 index 505104052c597..0000000000000 --- a/rb/spec/integration/selenium/webdriver/app_cache_spec.rb +++ /dev/null @@ -1,65 +0,0 @@ -# frozen_string_literal: true - -# Licensed to the Software Freedom Conservancy (SFC) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The SFC licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. - -require_relative 'spec_helper' - -module Selenium - module WebDriver - module DriverExtensions - describe 'HasApplicationCache', pending: 'Not supported in any driver.' do - it 'gets the app cache status' do - expect(driver.application_cache.status).to eq(:uncached) - - driver.online = false - driver.navigate.to url_for('html5Page.html') - - expect(browser.application_cache.status).to eq(:idle) - end - - it 'loads from cache when offline' do - driver.get url_for('html5Page.html') - driver.get url_for('formPage.html') - - driver.online = false - - driver.get url_for('html5Page.html') - expect(driver.title).to eq('HTML5') - end - - it 'gets the app cache entries' do - # dependant on spec above?! - - driver.get url_for('html5Page') - - entries = driver.application_cache.to_a - expect(entries.size).to be > 2 - - entries.each do |e| - case e.url - when /red\.jpg/ - expect(e.type.value).to eq(:master) - when /yellow\.jpg/ - expect(e.type.value).to eq(:explicit) - end - end - end - end - end # DriverExtensions - end # WebDriver -end # Selenium diff --git a/rb/spec/integration/selenium/webdriver/sql_database_spec.rb b/rb/spec/integration/selenium/webdriver/sql_database_spec.rb deleted file mode 100644 index fbdaed7678fd4..0000000000000 --- a/rb/spec/integration/selenium/webdriver/sql_database_spec.rb +++ /dev/null @@ -1,78 +0,0 @@ -# frozen_string_literal: true - -# Licensed to the Software Freedom Conservancy (SFC) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The SFC licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. - -require_relative 'spec_helper' - -module Selenium - module WebDriver - describe Driver do - context 'sql database', pending: 'Not supported in any driver.' do - let(:select) { 'SELECT * FROM docs' } - let(:insert) { 'INSERT INTO docs(docname) VALUES (?)' } - let(:delete) { 'DELETE from docs' } - let(:update) { "UPDATE docs SET docname='DocBar' WHERE docname='DocFooBar'" } - - before do - driver.get url_for('html5Page.html') - wait.until { driver.find_element(id: 'db_completed') } - end - - it 'includes inserted rows in the result set' do - driver.execute_sql insert, 'DocFoo' - driver.execute_sql insert, 'DocFooBar' - - result = driver.execute_sql select - expect(result.rows.size).to eq(2) - - expect(result.rows[0]['docname']).to eq('DocFoo') - expect(result.rows[1]['docname']).to eq('DocFooBar') - - driver.execute_sql delete - result = driver.execute_sql select - expect(result.rows.size).to eq(0) - end - - it 'knows the number of rows affected' do - result = driver.execute_sql insert, 'DocFooBar' - expect(result.rows_affected).to eq(1) - - result = driver.execute_sql select - expect(result.rows_affected).to eq(0) - - driver.execute_sql update - expect(result.rows.affected).to eq(1) - end - - it 'returns last inserted row id' do - result = driver.execute_sql select - expect(result.last_inserted_row_id).to eq(-1) - - driver.execute_sql insert, 'DocFoo' - expect(result.last_inserted_row_id).not_to eq(-1) - - result = driver.execute_sql select - expect(result.last_inserted_row_id).to eq(-1) - - result = driver.execute_sql delete - expect(result.last_inserted_row_id).to eq(-1) - end - end - end - end # WebDriver -end # Selenium