diff options
Diffstat (limited to 'deps/v8/test/unittests/test-utils.h')
-rw-r--r-- | deps/v8/test/unittests/test-utils.h | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/deps/v8/test/unittests/test-utils.h b/deps/v8/test/unittests/test-utils.h index 511e3574c8..42831a7db0 100644 --- a/deps/v8/test/unittests/test-utils.h +++ b/deps/v8/test/unittests/test-utils.h @@ -16,7 +16,7 @@ namespace v8 { std::ostream& operator<<(std::ostream&, ExternalArrayType); -class TestWithIsolate : public ::testing::Test { +class TestWithIsolate : public virtual ::testing::Test { public: TestWithIsolate(); virtual ~TestWithIsolate(); @@ -90,9 +90,9 @@ class TestWithIsolate : public virtual ::v8::TestWithIsolate { }; -class TestWithZone : public TestWithIsolate { +class TestWithZone : public virtual ::testing::Test { public: - TestWithZone() : zone_(isolate()) {} + TestWithZone() {} virtual ~TestWithZone(); Zone* zone() { return &zone_; } @@ -103,6 +103,21 @@ class TestWithZone : public TestWithIsolate { DISALLOW_COPY_AND_ASSIGN(TestWithZone); }; + +class TestWithIsolateAndZone : public virtual TestWithIsolate { + public: + TestWithIsolateAndZone() {} + virtual ~TestWithIsolateAndZone(); + + Zone* zone() { return &zone_; } + + private: + Zone zone_; + + DISALLOW_COPY_AND_ASSIGN(TestWithIsolateAndZone); +}; + + } // namespace internal } // namespace v8 |