browsed 0.2.8 → 0.2.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/browsed/browser.rb +2 -2
- data/lib/browsed/client.rb +2 -1
- data/lib/browsed/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 278284a08171aff994f5effaa073fe16176f25068251d4c4308c46fa6f6ba9b2
|
4
|
+
data.tar.gz: 99900aebcb0eefaa5b785eb8205fddfd496ed3b5197d2ceaaaf2f26ea7586e51
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ce6401a9d324063ba14eaf445ed2ca22dbd9cc88067b01b46ab32d346a99f155e587f9bd173021ec842b252bac85cd3d459dbbca4e0be477f2ea5d1d19668887
|
7
|
+
data.tar.gz: 0775e561f9b18f1123b0589c7f245d60215864c84566aa2d14ccc018edff50bd25204f71a26e264aee56b8429c55c84db716fb95bb360a638cb9751713e7ef6d
|
data/lib/browsed/browser.rb
CHANGED
@@ -9,8 +9,8 @@ module Browsed
|
|
9
9
|
def resize!(res = nil)
|
10
10
|
res ||= self.resolution
|
11
11
|
|
12
|
-
if res && res.size.eql?(2) && resizable_browser? # Resolutions for Chrome & Poltergeist are set in the driver
|
13
|
-
self.session
|
12
|
+
if self.session && res && res.size.eql?(2) && resizable_browser? # Resolutions for Chrome & Poltergeist are set in the driver
|
13
|
+
self.session&.current_window&.resize_to(res.first, res.last) # [width, height]
|
14
14
|
end
|
15
15
|
end
|
16
16
|
|
data/lib/browsed/client.rb
CHANGED
@@ -91,11 +91,12 @@ module Browsed
|
|
91
91
|
end
|
92
92
|
|
93
93
|
def reset_session!
|
94
|
-
self.session.reset_session!
|
94
|
+
self.session.reset_session! rescue nil
|
95
95
|
end
|
96
96
|
|
97
97
|
def quit!(retries: 3)
|
98
98
|
begin
|
99
|
+
reset_session!
|
99
100
|
self.session.driver.quit
|
100
101
|
rescue Exception
|
101
102
|
retries -= 1
|
data/lib/browsed/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: browsed
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sebastian
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-08-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: capybara
|