@@ -41,9 +41,9 @@ TEST_F(HotplugTest, schedulesConfigureToProcessHotplugEvents) {
4141 const auto & pendingEvents = mFlinger .mutablePendingHotplugEvents ();
4242 ASSERT_EQ (2u , pendingEvents.size ());
4343 EXPECT_EQ (hwcDisplayId1, pendingEvents[0 ].hwcDisplayId );
44- EXPECT_EQ (Connection::CONNECTED , pendingEvents[0 ].connection );
44+ EXPECT_EQ (HWComposer::HotplugEvent::Connected , pendingEvents[0 ].event );
4545 EXPECT_EQ (hwcDisplayId2, pendingEvents[1 ].hwcDisplayId );
46- EXPECT_EQ (Connection::DISCONNECTED , pendingEvents[1 ].connection );
46+ EXPECT_EQ (HWComposer::HotplugEvent::Disconnected , pendingEvents[1 ].event );
4747}
4848
4949TEST_F (HotplugTest, schedulesFrameToCommitDisplayTransaction) {
@@ -64,7 +64,7 @@ TEST_F(HotplugTest, createsDisplaySnapshotsForDisplaysWithIdentificationData) {
6464 using PrimaryDisplay = InnerDisplayVariant;
6565 PrimaryDisplay::setupHwcHotplugCallExpectations (this );
6666 PrimaryDisplay::setupHwcGetActiveConfigCallExpectations (this );
67- PrimaryDisplay::injectPendingHotplugEvent (this , Connection::CONNECTED );
67+ PrimaryDisplay::injectPendingHotplugEvent (this , HWComposer::HotplugEvent::Connected );
6868
6969 // TODO(b/241286146): Remove this unnecessary call.
7070 EXPECT_CALL (*mComposer ,
@@ -80,7 +80,7 @@ TEST_F(HotplugTest, createsDisplaySnapshotsForDisplaysWithIdentificationData) {
8080 using ExternalDisplay = ExternalDisplayWithIdentificationVariant;
8181 ExternalDisplay::setupHwcHotplugCallExpectations (this );
8282 ExternalDisplay::setupHwcGetActiveConfigCallExpectations (this );
83- ExternalDisplay::injectPendingHotplugEvent (this , Connection::CONNECTED );
83+ ExternalDisplay::injectPendingHotplugEvent (this , HWComposer::HotplugEvent::Connected );
8484
8585 // TODO(b/241286146): Remove this unnecessary call.
8686 EXPECT_CALL (*mComposer ,
@@ -123,7 +123,7 @@ TEST_F(HotplugTest, createsDisplaySnapshotsForDisplaysWithoutIdentificationData)
123123 using PrimaryDisplay = PrimaryDisplayVariant;
124124 PrimaryDisplay::setupHwcHotplugCallExpectations (this );
125125 PrimaryDisplay::setupHwcGetActiveConfigCallExpectations (this );
126- PrimaryDisplay::injectPendingHotplugEvent (this , Connection::CONNECTED );
126+ PrimaryDisplay::injectPendingHotplugEvent (this , HWComposer::HotplugEvent::Connected );
127127
128128 // TODO(b/241286146): Remove this unnecessary call.
129129 EXPECT_CALL (*mComposer ,
@@ -139,7 +139,7 @@ TEST_F(HotplugTest, createsDisplaySnapshotsForDisplaysWithoutIdentificationData)
139139 using ExternalDisplay = ExternalDisplayWithIdentificationVariant;
140140 ExternalDisplay::setupHwcHotplugCallExpectations (this );
141141 ExternalDisplay::setupHwcGetActiveConfigCallExpectations (this );
142- ExternalDisplay::injectPendingHotplugEvent (this , Connection::CONNECTED );
142+ ExternalDisplay::injectPendingHotplugEvent (this , HWComposer::HotplugEvent::Connected );
143143
144144 // TODO(b/241286146): Remove this unnecessary call.
145145 EXPECT_CALL (*mComposer ,
@@ -206,15 +206,15 @@ TEST_F(HotplugTest, ignoresDuplicateDisconnection) {
206206 // A single commit should be scheduled for both configure calls.
207207 EXPECT_CALL (*mFlinger .scheduler (), scheduleFrame (_)).Times (1 );
208208
209- ExternalDisplay::injectPendingHotplugEvent (this , Connection::CONNECTED );
209+ ExternalDisplay::injectPendingHotplugEvent (this , HWComposer::HotplugEvent::Connected );
210210 mFlinger .configure ();
211211
212212 EXPECT_TRUE (hasPhysicalHwcDisplay (ExternalDisplay::HWC_DISPLAY_ID));
213213
214214 // Disconnecting a display that was already disconnected should be a no-op.
215- ExternalDisplay::injectPendingHotplugEvent (this , Connection::DISCONNECTED );
216- ExternalDisplay::injectPendingHotplugEvent (this , Connection::DISCONNECTED );
217- ExternalDisplay::injectPendingHotplugEvent (this , Connection::DISCONNECTED );
215+ ExternalDisplay::injectPendingHotplugEvent (this , HWComposer::HotplugEvent::Disconnected );
216+ ExternalDisplay::injectPendingHotplugEvent (this , HWComposer::HotplugEvent::Disconnected );
217+ ExternalDisplay::injectPendingHotplugEvent (this , HWComposer::HotplugEvent::Disconnected );
218218 mFlinger .configure ();
219219
220220 // The display should be scheduled for removal during the next commit. At this point, it should
@@ -249,14 +249,14 @@ TEST_F(HotplugTest, rejectsHotplugIfFailedToLoadDisplayModes) {
249249
250250 EXPECT_CALL (*mFlinger .scheduler (), scheduleFrame (_)).Times (1 );
251251
252- ExternalDisplay::injectPendingHotplugEvent (this , Connection::CONNECTED );
252+ ExternalDisplay::injectPendingHotplugEvent (this , HWComposer::HotplugEvent::Connected );
253253 mFlinger .configure ();
254254
255255 // The hotplug should be rejected, so no HWComposer::DisplayData should be created.
256256 EXPECT_FALSE (hasPhysicalHwcDisplay (ExternalDisplay::HWC_DISPLAY_ID));
257257
258258 // Disconnecting a display that does not exist should be a no-op.
259- ExternalDisplay::injectPendingHotplugEvent (this , Connection::DISCONNECTED );
259+ ExternalDisplay::injectPendingHotplugEvent (this , HWComposer::HotplugEvent::Disconnected );
260260 mFlinger .configure ();
261261
262262 EXPECT_FALSE (hasPhysicalHwcDisplay (ExternalDisplay::HWC_DISPLAY_ID));
0 commit comments