when componentizing the chrome/renderer/spellchecker into components/spellcheck/renderer I had to add an explicit test_runner::EnsureBlinkInitialized() to avoid crashes in the following tests:
spellcheck_multilingual_unittest.cc
spellcheck_provider_test.cc
spellcheck_unittest.cc
without this initialization I get crash stacks with something like:
[ RUN ] SpellCheckTest.CreateTextCheckingResultsAddsGrammarMarkers
ASSERTION FAILED: s_initialized
../../third_party/WebKit/Source/wtf/allocator/Partitions.h(53) : static
WTF::PartitionRootGeneric *WTF::Partitions::bufferPartition()
it looks like the explicit init is typically needed for tests in components, we
have a couple of component tests doing a similar thing:
https://cs.chromium.org/search/?q=%22test_runner::EnsureBlinkInitialized();%22&sq=package:chromium&type=cs
however it has been pointed out by groby@ that this should not be necessary, hence this bug.
Comment 1 by timvolod...@chromium.org
, Aug 10 2016