• Andreas Haas's avatar
    [inspector] Dispose the isolate in the inspector tests · d9a91da6
    Andreas Haas authored
    At the moment the inspector tests do not dispose the isolate. This is a
    problem because the disposal of the isolate is used to stop the
    execution of background tasks. The missing disposal of the isolate
    caused flaky tests on the bots recently. With this CL the isolates of
    the inspector tests get disposed.
    
    The disposal of the isolate requires the following changes: 1) Store the
    isolate in a unique_ptr so that it gets disposed when the isolate-data
    gets disposed. It is necessary to use the unique_ptr so that the isolate
    gets disposed after other members of isolate-data get disposed.  2)
    Dispose all sessions. The reason is that the sessions require the
    isolate to exist when they get disposed because they own handles.
    Sessions, however, are stored in a static map, whereas the isolate is
    stored indirectly in a local variable of the main function. Since local
    variables get disposed before the static map is cleared, we have to
    clear the map before the end of the main function.
    
    R=kozyatinskiy@chromium.org
    
    Change-Id: Icb33184de254638b6cdfb899e940f18e6064cd69
    Reviewed-on: https://chromium-review.googlesource.com/774885Reviewed-by: 's avatarAleksey Kozyatinskiy <kozyatinskiy@chromium.org>
    Commit-Queue: Andreas Haas <ahaas@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#49424}
    d9a91da6
Name
Last commit
Last update
..
benchmarks Loading commit data...
cctest Loading commit data...
common Loading commit data...
debugger Loading commit data...
fuzzer Loading commit data...
inspector Loading commit data...
intl Loading commit data...
js-perf-test Loading commit data...
memory Loading commit data...
message Loading commit data...
mjsunit Loading commit data...
mkgrokdump Loading commit data...
mozilla Loading commit data...
preparser Loading commit data...
promises-aplus Loading commit data...
test262 Loading commit data...
unittests Loading commit data...
wasm-spec-tests Loading commit data...
webkit Loading commit data...
BUILD.gn Loading commit data...
bot_default.gyp Loading commit data...
bot_default.isolate Loading commit data...
default.gyp Loading commit data...
default.isolate Loading commit data...
optimize_for_size.gyp Loading commit data...
optimize_for_size.isolate Loading commit data...
perf.gyp Loading commit data...
perf.isolate Loading commit data...