capybara 3.4.1 → 3.4.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/History.md +7 -0
- data/lib/capybara/node/matchers.rb +1 -1
- data/lib/capybara/spec/session/element/matches_selector_spec.rb +11 -0
- data/lib/capybara/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: 8f5ec7ca4c922139d08198a15752604d048cb848ee93824e06c8d5c37d617b25
|
4
|
+
data.tar.gz: da7e6957df159f701ef63ce7a950f5ef951240f0f74a345558c8066d4c298f59
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6ac51efb716931eaf27df9d605c175efacbb15bc808d8f87f3ae880bff5bd493193952c47d58cf8088740f3a1b258d1f24e7a409b5ca682a602d7595f9930cbf
|
7
|
+
data.tar.gz: 77820939323587eb1e4a74ad3b31e0e93575a82fdad8a18c1ed239069790426db1c3017deced1e813bbeda7f6a148513a3fd74ee87db332b27ab15e722a9d702
|
data/History.md
CHANGED
@@ -709,7 +709,7 @@ module Capybara
|
|
709
709
|
query_args = _set_query_session_options(*query_args)
|
710
710
|
query = Capybara::Queries::MatchQuery.new(*query_args, &optional_filter_block)
|
711
711
|
synchronize(query.wait) do
|
712
|
-
yield query.resolve_for(query_scope)
|
712
|
+
yield query.resolve_for(self.first(:xpath, './parent::*', minimum: 0) || query_scope)
|
713
713
|
end
|
714
714
|
true
|
715
715
|
end
|
@@ -24,6 +24,17 @@ Capybara::SpecHelper.spec '#match_selector?' do
|
|
24
24
|
expect(@element).to match_selector('span.number')
|
25
25
|
end
|
26
26
|
|
27
|
+
it 'should work with elements located via a sibling selector' do
|
28
|
+
sibling = @element.sibling(:css, 'span', text: 'Other span')
|
29
|
+
expect(sibling).to match_selector(:xpath, '//span')
|
30
|
+
expect(sibling).to match_selector(:css, 'span')
|
31
|
+
end
|
32
|
+
|
33
|
+
it 'should work with the html element' do
|
34
|
+
html = @session.find('/html')
|
35
|
+
expect(html).to match_selector(:css, 'html')
|
36
|
+
end
|
37
|
+
|
27
38
|
context 'with text' do
|
28
39
|
it 'should discard all matches where the given string is not contained' do
|
29
40
|
expect(@element).to match_selector('//span', text: '42')
|
data/lib/capybara/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: capybara
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.4.
|
4
|
+
version: 3.4.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Thomas Walpole
|
@@ -10,7 +10,7 @@ autorequire:
|
|
10
10
|
bindir: bin
|
11
11
|
cert_chain:
|
12
12
|
- gem-public_cert.pem
|
13
|
-
date: 2018-07-
|
13
|
+
date: 2018-07-24 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: addressable
|