Upstream version 10.39.225.0
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / LayoutTests / http / tests / perf / resources / page-with-large-script.cgi
1 #!/usr/bin/perl -wT
2 use strict;
3
4 my (@out, $i, $n, $line);
5
6 push(@out, "Content-type: text/html\n");
7 push(@out, "\n");
8 push(@out, "<html>\n");
9 push(@out, "  <head>\n");
10 push(@out, "    <script>\n");
11
12 push(@out, "function foo() {\n");
13 push(@out, "  var q;\n");
14 $n = int($ENV{'QUERY_STRING'});
15 $line = "  q = 0; q = 1; q = 2; q = 3; q = 4; q = 5; q = 6; q = 7; q = 8; q = 9;\n";
16 for ($i = 0; $i < $n; $i++) {
17     push(@out, $line);
18 }
19 push(@out, "}\n");
20
21 push(@out, "    </script>\n");
22 push(@out, "  </head>\n");
23 push(@out, "  <body onload='parent._iframeLoaded();'>\n");
24 push(@out, "Bar\n");
25 push(@out, "  </body>\n");
26 push(@out, "</html>\n");
27 print join("", @out);