Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 86b91736 authored by Ale Nijamkin's avatar Ale Nijamkin Committed by Android (Google) Code Review
Browse files

Merge "Revert "Add unit test for WallpaperService.Engine#getRenderingSurfaceControl"" into main

parents 6debccf7 9083bd84
Loading
Loading
Loading
Loading
+0 −19
Original line number Diff line number Diff line
@@ -18,7 +18,6 @@ package android.service.wallpaper;

import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertNull;
import static org.junit.Assert.assertTrue;

import androidx.test.filters.SmallTest;
@@ -99,22 +98,4 @@ public class WallpaperServiceTest {

        engine.notifyColorsChanged();
    }

    @Test
    public void testGetRenderingSurfaceControl() {
        WallpaperService service = new WallpaperService() {
            @Override
            public Engine onCreateEngine() {
                return new Engine();
            }
        };
        WallpaperService.Engine engine = service.onCreateEngine();

        // Before the engine's surface is created and updated, this field is expected to be null.
        // A full integration test would be required to verify the non-null case, as creating a
        // real SurfaceControl requires significant setup. This unit test verifies the getter's
        // basic functionality and initial state.
        assertNull("getRenderingSurfaceControl should return null before surface creation",
                engine.getRenderingSurfaceControl());
    }
}