Home | History | Annotate | Download | only in kde

Lines Matching refs:RegExp

25 shouldBe("(new RegExp()).source", "'(?:)'");
26 shouldBe("Boolean(new RegExp())", "true");
27 shouldBeTrue("isNaN(Number(new RegExp()))");
29 // RegExp constructor called as a function
30 shouldBe("RegExp(/x/).source", "'x'");
31 //shouldBe("RegExp(/x/, 'g').source", "'/x/'"); // can't supply flags when constructing one RegExp from another, says mozilla
32 shouldBe("RegExp('x', 'g').global", "true");
33 shouldBe("RegExp('x').source", "'x'");
35 // RegExp constructor
36 shouldBe("new RegExp('x').source", "'x'");
71 shouldBe("var r = new RegExp(/x/); r.global=true; r.lastIndex = -1; typeof r.test('a')", "'boolean'");
75 shouldBe("RegExp.$1","'abc'");
76 shouldBe("RegExp.$2","'ghi'");
77 shouldBe("RegExp.$3","''");
80 shouldBe("RegExp.$1","'abcdefghi'");
81 shouldBe("RegExp.$2","'bcdefgh'");
82 shouldBe("RegExp.$3","'cdefg'");
83 shouldBe("RegExp.$4","'def'");
84 shouldBe("RegExp.$5","'e'");
85 shouldBe("RegExp.$6","''");
88 shouldBe("RegExp.$1","'100'");
89 shouldBe("RegExp.$3","'200'");
90 shouldBe("RegExp.$5","'150'");
91 shouldBe("RegExp.$7","'15'");
93 // After a failed match, cached results on the RegExp object are unchanged.
94 shouldBe("RegExp.$1","'100'");
95 shouldBe("RegExp.$3","'200'");
96 shouldBe("RegExp.$5","'150'");
97 shouldBe("RegExp.$7","'15'");
111 var caught = false; try { new RegExp("+"); } catch (e) { caught = true; }
124 shouldBe("RegExp.$1","'98 '");
125 shouldBe("RegExp.$2","''");
129 shouldBe("RegExp.$1","'76 '");
130 shouldBe("RegExp.$2","''");
140 // http://devedge.netscape.com/library/manuals/2000/javascript/1.5/guide/regexp.html
149 // regexp are writable ?
169 shouldBe("Object.prototype.toString.apply(RegExp.prototype)",
170         "'[object RegExp]'");
174 shouldBe("typeof RegExp.prototype.toString()", "'string'");
177 shouldBe("new RegExp().toString()", "'/(?:)/'");
178 shouldBe("(new RegExp('(?:)')).source", "'(?:)'");