Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Namespaces | Functions
testing.cc File Reference
#include "testing.h"
#include <utility>
#include "flutter/fml/file.h"
#include "flutter/fml/paths.h"

Go to the source code of this file.

Namespaces

namespace  flutter
 
namespace  flutter::testing
 

Functions

std::string flutter::testing::GetCurrentTestName ()
 Gets the name of the currently running test. This is useful in generating logs or assets based on test name.
 
std::string flutter::testing::GetDefaultKernelFilePath ()
 Returns the default path to kernel_blob.bin. This file is within the directory returned by GetFixturesPath().
 
fml::UniqueFD flutter::testing::OpenFixturesDirectory ()
 Opens the fixtures directory for the unit-test harness.
 
fml::UniqueFD flutter::testing::OpenFixture (const std::string &fixture_name)
 Opens a fixture of the given file name.
 
std::unique_ptr< fml::Mappingflutter::testing::OpenFixtureAsMapping (const std::string &fixture_name)
 Opens a fixture of the given file name and returns a mapping to its contents.
 
sk_sp< SkDataflutter::testing::OpenFixtureAsSkData (const std::string &fixture_name)
 Opens a fixture of the given file name and returns a Skia SkData holding its contents.
 
bool flutter::testing::MemsetPatternSetOrCheck (uint8_t *buffer, size_t size, MemsetPatternOp op)
 Depending on the operation, either scribbles a known pattern into the buffer or checks if that pattern is present in an existing buffer. This is a portable variant of the memset_pattern class of methods that also happen to do assert that the same pattern exists.
 
bool flutter::testing::MemsetPatternSetOrCheck (std::vector< uint8_t > &buffer, MemsetPatternOp op)