spec/lib/targets_spec.rb in RDee-0.3 vs spec/lib/targets_spec.rb in RDee-0.4
- old
+ new
@@ -209,17 +209,37 @@
expect(desired_capabilities).to receive(:platform=).with('OS X 10.9')
expect(watir_browser).to receive(:new).with(:remote, url: 'http://blah', desired_capabilities: anything())
RDee.watir_browser :iphone_ios71, url: 'http://blah'
end
- end
+ it "includes iPhone with ios 8.0" do
+ expect(desired_capabilities).to receive(:version=).with('8.0')
+ expect(desired_capabilities).to receive(:platform=).with('OS X 10.10')
+ expect(watir_browser).to receive(:new).with(:remote, url: 'http://blah', desired_capabilities: anything())
+ RDee.watir_browser :iphone_ios80, url: 'http://blah'
+ end
+ it "includes iPhone with ios 8.1" do
+ expect(desired_capabilities).to receive(:version=).with('8.1')
+ expect(desired_capabilities).to receive(:platform=).with('OS X 10.10')
+ expect(watir_browser).to receive(:new).with(:remote, url: 'http://blah', desired_capabilities: anything())
+ RDee.watir_browser :iphone_ios81, url: 'http://blah'
+ end
+end
+
context "for hosts" do
before(:each) do
allow(capabilities).to receive(:firefox).and_return(desired_capabilities)
end
+ it "should properly identify Windows 10" do
+ expect(desired_capabilities).to receive(:version=).with('30')
+ expect(desired_capabilities).to receive(:platform=).with('Windows 10')
+ expect(watir_browser).to receive(:new)
+ RDee.watir_browser :firefox30_win10, url: 'http://blah'
+ end
+
it "should properly identify Windows 8.1" do
expect(desired_capabilities).to receive(:version=).with('30')
expect(desired_capabilities).to receive(:platform=).with('Windows 8.1')
expect(watir_browser).to receive(:new)
RDee.watir_browser :firefox30_win81, url: 'http://blah'
@@ -244,14 +264,14 @@
expect(desired_capabilities).to receive(:platform=).with('Windows XP')
expect(watir_browser).to receive(:new)
RDee.watir_browser :firefox30_winxp, url: 'http://blah'
end
- it "should properly identify Snow Leopard" do
+ it "should properly identify El Capitan" do
expect(desired_capabilities).to receive(:version=).with('30')
- expect(desired_capabilities).to receive(:platform=).with('OS X 10.6')
+ expect(desired_capabilities).to receive(:platform=).with('OS X 10.11')
expect(watir_browser).to receive(:new)
- RDee.watir_browser :firefox30_snow_leopard, url: 'http://blah'
+ RDee.watir_browser :firefox30_el_capitan, url: 'http://blah'
end
it "should properly identify Mountain Lion" do
expect(desired_capabilities).to receive(:version=).with('30')
expect(desired_capabilities).to receive(:platform=).with('OS X 10.8')