File tree Expand file tree Collapse file tree 2 files changed +6
-1
lines changed
Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -49,7 +49,7 @@ module Rails::Dom::Testing::Assertions::SelectorAssertions
4949
5050 PATTERN_HTML = "['\" ]((\\ \\ \" |\\ \\ '|[^\" '])*)['\" ]"
5151 PATTERN_UNICODE_ESCAPED_CHAR = /\\ u([0-9a-zA-Z]{4})/
52- SKELETAL_PATTERN = "(?:jQuery|\\ $)\\ (%s\\ )\\ .%s\\ (%s\\ ); "
52+ SKELETAL_PATTERN = "(?:jQuery|\\ $)\\ (%s\\ )\\ .%s\\ (%s\\ )[;]? "
5353
5454 def assert_select_jquery ( *args , &block )
5555 jquery_method = args . first . is_a? ( Symbol ) ? args . shift : nil
Original file line number Diff line number Diff line change 1+ require 'ostruct'
12require_relative 'test_helper'
23require_relative '../lib/jquery/assert_select'
34
@@ -19,6 +20,9 @@ class AssertSelectJQueryTest < ActiveSupport::TestCase
1920 $("#cart tr:not(.total_line) > *").remove();
2021 $("[href|=\" val\" ][href$=\" val\" ][href^=\" val\" ]").remove();
2122 $("tr + td, li").remove();
23+
24+ // without semicolon
25+ $("#browser_cart").hide("blind", 1000)
2226 JS
2327
2428 setup do
@@ -28,6 +32,7 @@ class AssertSelectJQueryTest < ActiveSupport::TestCase
2832 def test_target_as_receiver
2933 assert_nothing_raised do
3034 assert_select_jquery :show , :blind , '#card'
35+ assert_select_jquery :hide , :blind , '#browser_cart'
3136 assert_select_jquery :html , '#id' do
3237 assert_select 'p' , 'something'
3338 end
You can’t perform that action at this time.
0 commit comments