#include "include/cppgc/cross-thread-persistent.h"
#include "include/cppgc/allocation.h"
#include "src/base/platform/condition-variable.h"
#include "src/base/platform/mutex.h"
#include "src/base/platform/platform.h"
#include "test/unittests/heap/cppgc/tests.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace cppgc {
namespace internal {
namespace {
struct GCed final : GarbageCollected<GCed> { … };
size_t GCed::destructor_call_count = …;
class Runner final : public v8::base::Thread { … };
}
class CrossThreadPersistentTest : public testing::TestWithHeap { … };
TEST_F(CrossThreadPersistentTest, RetainStronglyOnDifferentThread) { … }
TEST_F(CrossThreadPersistentTest, RetainWeaklyOnDifferentThread) { … }
TEST_F(CrossThreadPersistentTest, DestroyRacingWithGC) { … }
}
}