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
embedder_test_environment.h
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#ifndef TESTING_EMBEDDER_TEST_ENVIRONMENT_H_
6#define TESTING_EMBEDDER_TEST_ENVIRONMENT_H_
7
8#include <string>
9
10#include "public/fpdfview.h"
11#include "testing/gtest/include/gtest/gtest.h"
12#include "testing/test_fonts.h"
13
15 public:
18
19 // Note: GetInstance() does not create one if it does not exist,
20 // so the main program must explicitly add this enviroment.
22
23 // testing::Environment:
24 void SetUp() override;
25 void TearDown() override;
26
27 void AddFlags(int argc, char** argv);
28
29 bool write_pngs() const { return write_pngs_; }
30
31 private:
32 void AddFlag(const std::string& flag);
33
34 FPDF_RENDERER_TYPE renderer_type_;
35 bool write_pngs_ = false;
36 TestFonts test_fonts_;
37};
38
39#endif // TESTING_EMBEDDER_TEST_ENVIRONMENT_H_
void AddFlags(int argc, char **argv)
static EmbedderTestEnvironment * GetInstance()
void TearDown() override
TEST_F(FXGETextEmbedderTest, BadItalic)