Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(45)

Issue 8226016: Add the ability to run tests with several sets of VM flags (Closed)

Created:
9 years, 2 months ago by Søren Gjesse
Modified:
9 years, 2 months ago
Reviewers:
ngeoffray, Ivan Posva
CC:
reviews_dartlang.org, vm-dev_dartlang.org
Visibility:
Public.

Description

Add the ability to run tests with several sets of VM flags The test-option VMOptions that can be placed in .dart test files can now be specified several times like this: // VMOptions= // VMOptions=--short_socket_read // VMOptions=--short_socket_write // VMOptions=--short_socket_read --short_socket_write For each time VMOptions is specified a seperate test will be bun with the specified flags. Used this to run the tests that uses sockets with short read and writes. Fixed a number of bugs in both stream implementation and in tests revealed by this. R=iposva@google.com, ngeoffray@google.com Committed: https://code.google.com/p/dart/source/detail?r=388

Patch Set 1 #

Patch Set 2 : Minor fixes #

Patch Set 3 : Minor fix #

Patch Set 4 : Changed from usng VMShortReadWrite to using several VMOptions lines #

Patch Set 5 : Removed code in comments #

Total comments: 4

Patch Set 6 : Addressed comments from iposva@ #

Total comments: 10

Patch Set 7 : Addressed comments from ngeoffray@ #

Unified diffs Side-by-side diffs Delta from patch set Stats (+126 lines, -82 lines) Patch
M runtime/bin/socket_stream.dart View 1 2 1 chunk +9 lines, -6 lines 0 comments Download
M runtime/tests/dart/src/EchoServerStreamReadUntilTest.dart View 1 2 3 2 chunks +12 lines, -3 lines 0 comments Download
M runtime/tests/dart/src/EchoServerStreamTest.dart View 1 2 3 1 chunk +6 lines, -0 lines 0 comments Download
M runtime/tests/dart/src/EchoServerTest.dart View 1 2 3 5 chunks +36 lines, -42 lines 0 comments Download
M runtime/tests/dart/src/ProcessStderrTest.dart View 1 2 3 2 chunks +6 lines, -1 line 0 comments Download
M runtime/tests/dart/src/ProcessStdoutTest.dart View 1 2 3 2 chunks +5 lines, -2 lines 0 comments Download
M tools/testing/architecture.py View 1 2 3 4 5 3 chunks +2 lines, -10 lines 0 comments Download
M tools/testing/test_case.py View 1 2 3 4 5 6 2 chunks +4 lines, -1 line 0 comments Download
M tools/testing/test_configuration.py View 1 2 3 4 5 6 4 chunks +19 lines, -4 lines 0 comments Download
M tools/utils.py View 1 2 3 4 5 6 1 chunk +27 lines, -13 lines 0 comments Download

Messages

Total messages: 7 (0 generated)
Søren Gjesse
9 years, 2 months ago (2011-10-12 09:21:58 UTC) #1
Ivan Posva
As we discussed in person, we should instead use an extensible approach. If a test ...
9 years, 2 months ago (2011-10-12 13:53:57 UTC) #2
Søren Gjesse
Changed the approach to use several VMOptions lines. PTAL
9 years, 2 months ago (2011-10-13 07:03:27 UTC) #3
Ivan Posva
LGTM -ip http://codereview.chromium.org/8226016/diff/10001/tools/testing/architecture.py File tools/testing/architecture.py (right): http://codereview.chromium.org/8226016/diff/10001/tools/testing/architecture.py#newcode376 tools/testing/architecture.py:376: return ExeuteCommand(command, verbose) ? http://codereview.chromium.org/8226016/diff/10001/tools/testing/test_configuration.py File tools/testing/test_configuration.py ...
9 years, 2 months ago (2011-10-13 07:17:33 UTC) #4
Søren Gjesse
http://codereview.chromium.org/8226016/diff/10001/tools/testing/architecture.py File tools/testing/architecture.py (right): http://codereview.chromium.org/8226016/diff/10001/tools/testing/architecture.py#newcode376 tools/testing/architecture.py:376: return ExeuteCommand(command, verbose) On 2011/10/13 07:17:34, Ivan Posva wrote: ...
9 years, 2 months ago (2011-10-13 07:28:15 UTC) #5
ngeoffray
LGTM! http://codereview.chromium.org/8226016/diff/13001/tools/testing/test_case.py File tools/testing/test_case.py (right): http://codereview.chromium.org/8226016/diff/13001/tools/testing/test_case.py#newcode27 tools/testing/test_case.py:27: def __init__(self, context, path, filename, mode, arch, vm_options ...
9 years, 2 months ago (2011-10-13 07:53:24 UTC) #6
Søren Gjesse
9 years, 2 months ago (2011-10-13 08:57:07 UTC) #7
http://codereview.chromium.org/8226016/diff/13001/tools/testing/test_case.py
File tools/testing/test_case.py (right):

http://codereview.chromium.org/8226016/diff/13001/tools/testing/test_case.py#...
tools/testing/test_case.py:27: def __init__(self, context, path, filename, mode,
arch, vm_options = None):
On 2011/10/13 07:53:24, ngeoffray wrote:
> vm_options = [] ? and then you can remove the null check?

Done.

http://codereview.chromium.org/8226016/diff/13001/tools/testing/test_case.py#...
tools/testing/test_case.py:38: for vm_option in vm_options:
On 2011/10/13 07:53:24, ngeoffray wrote:
> for flag in vm_options

Done.

http://codereview.chromium.org/8226016/diff/13001/tools/testing/test_case.py#...
tools/testing/test_case.py:39: if (len(vm_option) > 0):
On 2011/10/13 07:53:24, ngeoffray wrote:
> Maybe you could avoid this len check by doing it before calling this method?
It
> looks silly to check it on each vm flag.

Done.

http://codereview.chromium.org/8226016/diff/13001/tools/testing/test_configur...
File tools/testing/test_configuration.py (right):

http://codereview.chromium.org/8226016/diff/13001/tools/testing/test_configur...
tools/testing/test_configuration.py:76: if arch in ['ia32', 'x64', 'simarm',
'arm']:
On 2011/10/13 07:53:24, ngeoffray wrote:
> I don't think we want to filter on the arch. The feature is also useful for
the
> other archs (yes, VMOptions is misleading).

Done.

http://codereview.chromium.org/8226016/diff/13001/tools/testing/test_configur...
tools/testing/test_configuration.py:81: vm_options =
utils.ParseTestOptionsMultiple(VM_OPTIONS_PATTERN,
On 2011/10/13 07:53:24, ngeoffray wrote:
> vm_options_list = ?

Done.

Powered by Google App Engine
This is Rietveld 408576698