diff --git a/gfx/layers/apz/test/gtest/TestHitTesting.cpp b/gfx/layers/apz/test/gtest/TestHitTesting.cpp index 597227ab7fb3..1f2af933158e 100644 --- a/gfx/layers/apz/test/gtest/TestHitTesting.cpp +++ b/gfx/layers/apz/test/gtest/TestHitTesting.cpp @@ -80,14 +80,7 @@ class APZHitTestingTester : public APZCTreeManagerTester { } }; -class APZHitTestingTesterInternal : public APZHitTestingTester { - public: - APZHitTestingTesterInternal() { - mHitTester = MakeUnique(); - } -}; - -TEST_F(APZHitTestingTesterInternal, ComplexMultiLayerTree) { +TEST_F(APZHitTestingTester, ComplexMultiLayerTree) { CreateComplexMultiLayerTree(); ScopedLayerTreeRegistration registration(LayersId{0}, mcc); UpdateHitTestingTree(); @@ -163,12 +156,8 @@ TEST_F(APZHitTestingTesterInternal, ComplexMultiLayerTree) { EXPECT_EQ(nullptr, node8->GetLastChild()); EXPECT_EQ(nullptr, node9->GetLastChild()); - RefPtr hit = GetTargetAPZC(ScreenPoint(25, 25)); - EXPECT_EQ(ApzcOf(layers[1]), hit.get()); - hit = GetTargetAPZC(ScreenPoint(275, 375)); - EXPECT_EQ(ApzcOf(layers[9]), hit.get()); - hit = GetTargetAPZC(ScreenPoint(250, 100)); - EXPECT_EQ(ApzcOf(layers[7]), hit.get()); + // Assertions about hit-testing have been ported to mochitest, + // in helper_hittest_bug1730606-4.html. } TEST_F(APZHitTestingTester, TestRepaintFlushOnNewInputBlock) { diff --git a/gfx/layers/apz/test/mochitest/helper_hittest_bug1730606-4.html b/gfx/layers/apz/test/mochitest/helper_hittest_bug1730606-4.html new file mode 100644 index 000000000000..26ec487b3ef7 --- /dev/null +++ b/gfx/layers/apz/test/mochitest/helper_hittest_bug1730606-4.html @@ -0,0 +1,194 @@ + + + + A hit testing test involving a scenario with a scale transform + + + + + + + +
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ + + diff --git a/gfx/layers/apz/test/mochitest/test_group_hittest-2.html b/gfx/layers/apz/test/mochitest/test_group_hittest-2.html index f9df037cdfcf..12043c110ae0 100644 --- a/gfx/layers/apz/test/mochitest/test_group_hittest-2.html +++ b/gfx/layers/apz/test/mochitest/test_group_hittest-2.html @@ -47,6 +47,7 @@ var subtests = [ {"file": "helper_hittest_bug1730606-1.html", "prefs": prefs}, {"file": "helper_hittest_bug1730606-2.html", "prefs": prefs}, {"file": "helper_hittest_bug1730606-3.html", "prefs": prefs}, + {"file": "helper_hittest_bug1730606-4.html", "prefs": prefs}, // This test should be at the end, because it's prone to timeout. {"file": "helper_hittest_spam.html", "prefs": prefs}, ];