softwear-lib 1.8.5 → 1.8.6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 44ddb5561ba7854b42a449e5dcc602f7a12fe15d
4
- data.tar.gz: 802c5fd8137b31d26cc1afb3632962c2a02de4c4
3
+ metadata.gz: 6cb3780d4d6c6f6f76f66cd1c44bba64c44abe4b
4
+ data.tar.gz: d03c878e349fc7dbe96babd04c0fdceccbdebed5
5
5
  SHA512:
6
- metadata.gz: 3c687adbd0fd0f6112ae01f1de28da66f2ea814bb7fe33471017ae900e0086476b728fb9cd1d843cf3bbbee49dcc52583f622498b530f2cb8958df39afbefde3
7
- data.tar.gz: 7f46608f690f829b779cef2e861c9d32421b75a66f006c27b49b74dd789204e072f266ebabe078f6b5aa873b9c350ed9eebf4dfc4cae60c66230e5e5d5e3dc6f
6
+ metadata.gz: 95208a77b99f5b8629e9e3b3221d1fa6326a11f302a50cad9da1bdd960ed24a91d0d2927acfd3eca84b0adb33fe4d9c7754005b926b89c4abdb60eb57886eb01
7
+ data.tar.gz: 3034f8d991490d07061a718746e1e55d04d0f8069c79cc41a95e77b254fd0d5a5a90fddb898b263e9e004c1c86f1816a1c3421f4d9bc81a4763a1d64a3bff9a7
@@ -86,12 +86,16 @@ module Softwear::Lib
86
86
  def select2(text, options)
87
87
  label = find_label_by_text(options[:from], try: true)
88
88
  if label
89
- selector = "select[name='#{label['for']}'],select[id='#{label['for']}']"
89
+ selector = "select[name='#{label['for']}']+span,select[id='#{label['for']}']+span"
90
90
  else
91
- selector = options[:from]
91
+ selector = "#{options[:from]}+span"
92
92
  end
93
93
 
94
- find("#{selector}+span").click
94
+ if options[:last]
95
+ all(selector).last.click
96
+ else
97
+ find(selector).click
98
+ end
95
99
 
96
100
  old_scopes = page.instance_variable_get(:@scopes)
97
101
  page.instance_variable_set(:@scopes, [nil])
@@ -1,5 +1,5 @@
1
1
  module Softwear
2
2
  module Lib
3
- VERSION = "1.8.5"
3
+ VERSION = "1.8.6"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: softwear-lib
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.8.5
4
+ version: 1.8.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nigel Baillie
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-06-01 00:00:00.000000000 Z
11
+ date: 2016-06-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler