ae_page_objects 0.1.2.dt1 → 0.1.2.dt2

Sign up to get free protection for your applications and to get access to all the features.
@@ -20,7 +20,7 @@ module AePageObjects
20
20
  raise ArgumentError, ":name or :locator is required" unless @name || @locator
21
21
 
22
22
  @locator ||= default_locator
23
-
23
+
24
24
  super(scoped_node)
25
25
  end
26
26
 
@@ -38,7 +38,7 @@ module AePageObjects
38
38
 
39
39
  def __full_name__
40
40
  if parent.respond_to?(:__full_name__)
41
- [ parent.__full_name__, __name__ ].compact.join('_')
41
+ [ parent.__full_name__, __name__ ].compact.presence.try(:join, '_')
42
42
  else
43
43
  __name__
44
44
  end
@@ -1,3 +1,3 @@
1
1
  module AePageObjects
2
- VERSION = '0.1.2.dt1'.freeze
2
+ VERSION = '0.1.2.dt2'.freeze
3
3
  end
@@ -36,14 +36,14 @@ module AePageObjects
36
36
  end
37
37
 
38
38
  def switch_to
39
- Capybara.current_session.driver.browser.switch_to(handle)
39
+ Capybara.current_session.driver.browser.switch_to.window(handle)
40
40
  current_document
41
41
  end
42
42
 
43
43
  def close
44
44
  self.current_document = nil
45
45
 
46
- Capybara.current_session.driver.close
46
+ Capybara.current_session.execute_script("window.close();")
47
47
 
48
48
  self.class.all.delete(self)
49
49
  end
metadata CHANGED
@@ -1,15 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ae_page_objects
3
3
  version: !ruby/object:Gem::Version
4
- hash: 631108069
4
+ hash: 115207405
5
5
  prerelease: 6
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
9
  - 2
10
10
  - dt
11
- - 1
12
- version: 0.1.2.dt1
11
+ - 2
12
+ version: 0.1.2.dt2
13
13
  platform: ruby
14
14
  authors:
15
15
  - Donnie Tognazzini