Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
fxv8_unittest.cpp
Go to the documentation of this file.
1
// Copyright 2020 The PDFium Authors
2
// Use of this source code is governed by a BSD-style license that can be
3
// found in the LICENSE file.
4
5
#
include
"testing/fxv8_unittest.h"
6
7
#
include
<
memory
>
8
9
#
include
"fxjs/cfx_v8_array_buffer_allocator.h"
10
#
include
"v8/include/v8-isolate.h"
11
12
void
FXV8UnitTest
::
V8IsolateDeleter
::
operator
()(
v8
::Isolate* ptr)
const
{
13
ptr->Dispose();
14
}
15
16
FXV8UnitTest
::
FXV8UnitTest
() =
default
;
17
18
FXV8UnitTest
::~
FXV8UnitTest
() =
default
;
19
20
void
FXV8UnitTest
::
SetUp
() {
21
array_buffer_allocator_ = std::make_unique<CFX_V8ArrayBufferAllocator>();
22
23
v8::Isolate::CreateParams params;
24
params.array_buffer_allocator = array_buffer_allocator_.get();
25
isolate_.reset(v8::Isolate::New(params));
26
}
FXV8UnitTest
Definition
fxv8_unittest.h:19
FXV8UnitTest::FXV8UnitTest
FXV8UnitTest()
FXV8UnitTest::SetUp
void SetUp() override
Definition
fxv8_unittest.cpp:20
FXV8UnitTest::~FXV8UnitTest
~FXV8UnitTest() override
v8
Definition
fxv8_unittest.h:15
FXV8UnitTest::V8IsolateDeleter
Definition
fxv8_unittest.h:21
FXV8UnitTest::V8IsolateDeleter::operator()
void operator()(v8::Isolate *ptr) const
Definition
fxv8_unittest.cpp:12
qtwebengine
src
3rdparty
chromium
third_party
pdfium
testing
fxv8_unittest.cpp
Generated on Wed Nov 13 2024 01:03:38 for Qt by
1.12.0