mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
* Re-land "Support multiple shells in a single process. (#4932)" This reverts commit 723c7d01439da4261bc836075fb55651ce9e7f03.
22 lines
655 B
C++
22 lines
655 B
C++
// Copyright 2017 The Flutter Authors. All rights reserved.
|
|
// Use of this source code is governed by a BSD-style license that can be
|
|
// found in the LICENSE file.
|
|
|
|
#include "flutter/runtime/dart_vm.h"
|
|
#include "gtest/gtest.h"
|
|
|
|
namespace blink {
|
|
|
|
TEST(DartVM, SimpleInitialization) {
|
|
Settings settings = {};
|
|
settings.task_observer_add = [](intptr_t, fxl::Closure) {};
|
|
settings.task_observer_remove = [](intptr_t) {};
|
|
auto vm = DartVM::ForProcess(settings);
|
|
ASSERT_TRUE(vm);
|
|
ASSERT_EQ(vm, DartVM::ForProcess(settings));
|
|
ASSERT_FALSE(DartVM::IsRunningPrecompiledCode());
|
|
ASSERT_EQ(vm->GetPlatformKernel(), nullptr);
|
|
}
|
|
|
|
} // namespace blink
|