tizen beta release
[profile/ivi/webkit-efl.git] / LayoutTests / fast / js / script-tests / regexp-overflow-too-big.js
1 description('Tests a regular expression that hits the recursion limit.');
2
3 var complexPattern = "";
4 for (var i = 0; i < 18; ++i)
5     complexPattern += "a?";
6 for (var i = 0; i < 18; ++i)
7     complexPattern += "a";
8 complexPattern = "\1(" + complexPattern + ")";
9
10 var complexInput = "";
11 for (var i = 0; i < 18; ++i)
12     complexInput += "a";
13
14 shouldBe('new RegExp(complexPattern + complexPattern).exec(complexInput + complexInput)', 'null'); // Too big