require 'spec_helper'

describe 'Mozilla Firefox' do
  before(:all) do
    @selenium = Selenium::WebDriver.for(:remote, url: "http://localhost:4446/wd/hub", desired_capabilities: :firefox)
  end

  after(:all) do
    @selenium.quit
  end

  res = '1024 x 768'

  it "should return display resolution of #{res}" do
    @selenium.get 'http://www.whatismyscreenresolution.com/'
    element = @selenium.find_element(:id, 'resolutionNumber')
    expect(element.text).to eq(res)
  end
end

require 'spec_helper'

describe 'Mozilla Firefox' do
  before(:all) do
    @selenium = Selenium::WebDriver.for(:remote, url: "http://localhost:4446/wd/hub", desired_capabilities: :firefox)
  end

  after(:all) do
    @selenium.quit
  end

  res = '1024 x 7688'

  it "should return display resolution of #{res}" do
    @selenium.get 'http://www.whatismyscreenresolution.com/'
    element = @selenium.find_element(:id, 'resolutionNumber')
    expect(element.text).to eq(res)
  end
end

Validate that rspec test of firefox fails
Validate that rspec test of firefox fails
