diff options
author | Timm <kaspth@gmail.com> | 2013-07-25 20:04:27 +0200 |
---|---|---|
committer | Timm <kaspth@gmail.com> | 2014-06-16 21:03:57 +0200 |
commit | 7e7e19132d2206831b824039a362aa378a4ef70e (patch) | |
tree | 490a8519afe422031f3a81ed1e7ffc9911ab1852 /actionpack/lib/action_dispatch/testing/assertions | |
parent | 2cc4f4258a61dd638da2f72d27b26753a72f886f (diff) | |
download | rails-7e7e19132d2206831b824039a362aa378a4ef70e.tar.gz rails-7e7e19132d2206831b824039a362aa378a4ef70e.tar.bz2 rails-7e7e19132d2206831b824039a362aa378a4ef70e.zip |
Added NodeSet comparison to possible root element in determine_root_from.
Diffstat (limited to 'actionpack/lib/action_dispatch/testing/assertions')
-rw-r--r-- | actionpack/lib/action_dispatch/testing/assertions/selector.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/actionpack/lib/action_dispatch/testing/assertions/selector.rb b/actionpack/lib/action_dispatch/testing/assertions/selector.rb index 53e7675f7c..9b03ccce14 100644 --- a/actionpack/lib/action_dispatch/testing/assertions/selector.rb +++ b/actionpack/lib/action_dispatch/testing/assertions/selector.rb @@ -367,7 +367,7 @@ module ActionDispatch @css_selector_is_second_argument = false if root_or_selector == nil raise ArgumentError, "First argument is either selector or element to select, but nil found. Perhaps you called assert_select with an element that does not exist?" - elsif root_or_selector.is_a?(Nokogiri::XML::Node) + elsif root_or_selector.is_a?(Nokogiri::XML::Node) || root_or_selector.is_a?(Nokogiri::XML::NodeSet) # First argument is a node (tag or text, but also HTML root), # so we know what we're selecting from. @css_selector_is_second_argument = true |