diff --git a/test/src/test/java/scripts/BehaviorTest.java b/test/src/test/java/scripts/BehaviorTest.java index cd23aaa619..9c6cf719ba 100644 --- a/test/src/test/java/scripts/BehaviorTest.java +++ b/test/src/test/java/scripts/BehaviorTest.java @@ -41,6 +41,10 @@ public class BehaviorTest extends HudsonTestCase { // 'includeSelf' should only affect the first axis and not afterward assertEquals(1,asInt(p.executeJavaScript("findElementsBySelector($('test2'),'.a .b',true).length"))); assertEquals(1,asInt(p.executeJavaScript("findElementsBySelector($('test2'),'.a .b',false).length"))); + + // tag.class. Should exclude itself anyway even if it's included + assertEquals(1,asInt(p.executeJavaScript("findElementsBySelector($('test3'),'P.a',true).length"))); + assertEquals(1,asInt(p.executeJavaScript("findElementsBySelector($('test3'),'P.a',false).length"))); } private int asInt(ScriptResult r) { diff --git a/test/src/test/resources/scripts/BehaviorTest/testCssSelectors.jelly b/test/src/test/resources/scripts/BehaviorTest/testCssSelectors.jelly index cad343e1cc..61f6ba8daa 100644 --- a/test/src/test/resources/scripts/BehaviorTest/testCssSelectors.jelly +++ b/test/src/test/resources/scripts/BehaviorTest/testCssSelectors.jelly @@ -38,6 +38,10 @@ THE SOFTWARE. +