Reapply Avoid sending powerhint right after GPU composition.

The change in 8ec87f8c6d72084c919d99680ee770bf1635cd26 was
unintentionally dropped in moving the code to CompositionEngine.

Bug: 147398431
Test: atest libcomposition_test
Test: go/wm-smoke
Test CtsColorModeTestCases CtsDisplayTestCases CtsGraphicsTestCases CtsMediaTestCases CtsUiRenderingTestCases CtsViewTestCases
Change-Id: Ia652c04abf6e5094b399483948553f2aaffd0aea
diff --git a/services/surfaceflinger/CompositionEngine/tests/OutputTest.cpp b/services/surfaceflinger/CompositionEngine/tests/OutputTest.cpp
index cb6c50c..80528e3 100644
--- a/services/surfaceflinger/CompositionEngine/tests/OutputTest.cpp
+++ b/services/surfaceflinger/CompositionEngine/tests/OutputTest.cpp
@@ -2842,9 +2842,11 @@
                          OutputComposeSurfacesTest::kDefaultAvgLuminance,
                          OutputComposeSurfacesTest::kDefaultMinLuminance};
 
-TEST_F(OutputComposeSurfacesTest, doesNothingIfNoClientComposition) {
+TEST_F(OutputComposeSurfacesTest, doesNothingButSignalNoExpensiveRenderingIfNoClientComposition) {
     mOutput.mState.usesClientComposition = false;
 
+    EXPECT_CALL(mOutput, setExpensiveRenderingExpected(false));
+
     verify().execute().expectAFenceWasReturned();
 }
 
@@ -3163,7 +3165,6 @@
 
     EXPECT_CALL(mOutput, setExpensiveRenderingExpected(true));
     EXPECT_CALL(mRenderEngine, drawLayers(_, _, _, true, _, _)).WillOnce(Return(NO_ERROR));
-    EXPECT_CALL(mOutput, setExpensiveRenderingExpected(false));
 
     mOutput.composeSurfaces(kDebugRegion);
 }