diff options
author | sgjesse@google.com <sgjesse@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-10-26 07:18:26 +0000 |
---|---|---|
committer | sgjesse@google.com <sgjesse@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-10-26 07:18:26 +0000 |
commit | 1c5337879d661bb22be4e4dd49fee0283f767f44 (patch) | |
tree | beccaf66e85ddec6a62b345a21f20f658e96e984 /webkit/tools/test_shell/test_shell_mac.mm | |
parent | 5f38d719c386c354b118224999c710a6fe22f92e (diff) | |
download | chromium_src-1c5337879d661bb22be4e4dd49fee0283f767f44.zip chromium_src-1c5337879d661bb22be4e4dd49fee0283f767f44.tar.gz chromium_src-1c5337879d661bb22be4e4dd49fee0283f767f44.tar.bz2 |
Add an option to the test_shell to enable it to load each test several times
We have sees bugs which could have been caught by reloading a page one or more times and finding that the results for one of the subsequent loads is not the same as the expected output. The new option--multiple-loads=X will load each test X time. The output dumped by test_shell is the result of the last load. The default when the option is specified without a value is 2 times in debug mode and 5 times in release mode.
To be able to have more fine-grained control of how the JavaScript engine behaves for each load the existing flag --js-flags can now specify a list of flag-sets like this
--js-flags="--xxx,--noxxx --yyy,--noyyy"
First load will run with --xxx, the second with --yyy and the third without any (the 'no' prefix is handled by V8 to turn off the flag).
The changes to the Python test runner will be in a separate change.
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/4016002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@63863 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/tools/test_shell/test_shell_mac.mm')
-rw-r--r-- | webkit/tools/test_shell/test_shell_mac.mm | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/webkit/tools/test_shell/test_shell_mac.mm b/webkit/tools/test_shell/test_shell_mac.mm index d2b90a7..30eab0f 100644 --- a/webkit/tools/test_shell/test_shell_mac.mm +++ b/webkit/tools/test_shell/test_shell_mac.mm @@ -370,10 +370,12 @@ void TestShell::TestFinished() { return; // reached when running under test_shell_tests test_is_pending_ = false; - NSWindow* window = *(TestShell::windowList()->begin()); - WindowMap::iterator it = window_map_.Get().find(window); - if (it != window_map_.Get().end()) - TestShell::Dump(it->second); + if (dump_when_finished_) { + NSWindow* window = *(TestShell::windowList()->begin()); + WindowMap::iterator it = window_map_.Get().find(window); + if (it != window_map_.Get().end()) + TestShell::Dump(it->second); + } MessageLoop::current()->Quit(); } |