mirror of
https://pdfium.googlesource.com/pdfium
synced 2026-08-03 11:00:54 +08:00
Updates old-style copyright headers to the new style, by removing "All rights reserved." Also inserts "The" before "PDFium Authors", which is required by both styles. Mechanically generated by this command: PATTERN='Copyright \([0-9]\+\) \(The \)\?PDFium Authors. All rights reserved.' git grep -l "$PATTERN" \ | xargs sed "s/$PATTERN/Copyright \1 The PDFium Authors/" -i'' Fixed: pdfium:1884 Change-Id: I6f781d811df8839e2e21b85f716529b813828bcd Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/100371 Reviewed-by: Lei Zhang <thestig@chromium.org> Commit-Queue: K. Moon <kmoon@chromium.org>
38 lines
1.0 KiB
C++
38 lines
1.0 KiB
C++
// Copyright 2020 The PDFium Authors
|
|
// Use of this source code is governed by a BSD-style license that can be
|
|
// found in the LICENSE file.
|
|
|
|
#include "testing/external_engine_embedder_test.h"
|
|
|
|
#include <memory>
|
|
|
|
#include "fxjs/cfxjs_engine.h"
|
|
#include "testing/v8_test_environment.h"
|
|
#include "v8/include/v8-context.h"
|
|
#include "v8/include/v8-isolate.h"
|
|
#include "v8/include/v8-local-handle.h"
|
|
|
|
ExternalEngineEmbedderTest::ExternalEngineEmbedderTest() = default;
|
|
|
|
ExternalEngineEmbedderTest::~ExternalEngineEmbedderTest() = default;
|
|
|
|
void ExternalEngineEmbedderTest::SetUp() {
|
|
EmbedderTest::SetUp();
|
|
|
|
v8::Isolate::Scope isolate_scope(isolate());
|
|
v8::HandleScope handle_scope(isolate());
|
|
FXJS_PerIsolateData::SetUp(isolate());
|
|
m_Engine = std::make_unique<CFXJS_Engine>(isolate());
|
|
m_Engine->InitializeEngine();
|
|
}
|
|
|
|
void ExternalEngineEmbedderTest::TearDown() {
|
|
m_Engine->ReleaseEngine();
|
|
m_Engine.reset();
|
|
JSEmbedderTest::TearDown();
|
|
}
|
|
|
|
v8::Local<v8::Context> ExternalEngineEmbedderTest::GetV8Context() {
|
|
return m_Engine->GetV8Context();
|
|
}
|