#include "include/v8-template.h"
#include "src/api/api-inl.h"
#include "src/debug/debug.h"
#include "src/execution/frames-inl.h"
#include "src/flags/flags.h"
#include "src/heap/read-only-spaces.h"
#include "test/cctest/cctest.h"
#include "tools/debug_helper/debug-helper.h"
namespace v8 {
namespace internal {
namespace {
d;
uintptr_t memory_fail_start = …;
uintptr_t memory_fail_end = …;
class MemoryFailureRegion { … };
d::MemoryAccessResult ReadMemory(uintptr_t address, void* destination,
size_t byte_count) { … }
void CheckPropBase(const d::PropertyBase& property, const char* expected_type,
const char* expected_name) { … }
void CheckProp(const d::ObjectProperty& property, const char* expected_type,
const char* expected_name,
d::PropertyKind expected_kind = d::PropertyKind::kSingle,
size_t expected_num_values = 1) { … }
template <typename TValue>
void CheckProp(const d::ObjectProperty& property, const char* expected_type,
const char* expected_name, TValue expected_value) { … }
bool StartsWith(const std::string& full_string, const std::string& prefix) { … }
bool Contains(const std::string& full_string, const std::string& substr) { … }
void CheckStructProp(const d::StructProperty& property,
const char* expected_type, const char* expected_name,
size_t expected_offset, uint8_t expected_num_bits = 0,
uint8_t expected_shift_bits = 0) { … }
const d::ObjectProperty& FindProp(const d::ObjectPropertiesResult& props,
std::string name) { … }
template <typename TValue>
TValue ReadProp(const d::ObjectPropertiesResult& props, std::string name) { … }
class StringResource : public v8::String::ExternalStringResource { … };
}
class TestDebugHelper { … };
TEST(GetObjectProperties) { … }
static void FrameIterationCheck(
v8::Local<v8::Name> name, const v8::PropertyCallbackInfo<v8::Value>& info) { … }
THREADED_TEST(GetFrameStack) { … }
TEST(SmallOrderedHashSetGetObjectProperties) { … }
}
}