mirror of
https://github.com/Droid-Deck/DroidDeck.git
synced 2026-11-19 04:46:08 +00:00
feat: add immersive Quest SteamVR to the standard app (#910)
This commit is contained in:
1 parent
559120313a
commit
679e3d8934
73 files changed
+5916
-289
No files matched your search
@@ -0,0 +1,28 @@
|
||||
package com.droiddeck.launcher.session
|
||||
|
||||
import org.junit.Assert.assertFalse
|
||||
import org.junit.Assert.assertTrue
|
||||
import org.junit.Test
|
||||
|
||||
class SessionVisibilityTest {
|
||||
@Test fun xrVisibilitySurvivesPanelHandoffAndPanelScreenState() {
|
||||
for (panelVisible in listOf(false, true)) {
|
||||
for (screenOn in listOf(false, true)) {
|
||||
assertTrue(sessionHasVisibleSurface(panelVisible, screenOn, true))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Test fun normalPanelStillRequiresAnInteractiveScreen() {
|
||||
assertTrue(sessionHasVisibleSurface(true, true, false))
|
||||
assertFalse(sessionHasVisibleSurface(false, true, false))
|
||||
assertFalse(sessionHasVisibleSurface(true, false, false))
|
||||
assertFalse(sessionHasVisibleSurface(false, false, false))
|
||||
}
|
||||
|
||||
@Test fun losingXrVisibilityReturnsToNormalSuspendRules() {
|
||||
assertTrue(sessionHasVisibleSurface(false, false, true))
|
||||
assertFalse(sessionHasVisibleSurface(false, false, false))
|
||||
assertTrue(sessionHasVisibleSurface(true, true, false))
|
||||
}
|
||||
}
|
||||
@@ -20,7 +20,9 @@ class SessionDrawerPageTest {
|
||||
assertEquals(sessionDrawerPages(false), connected.filter { it != SessionDrawerPage.SECOND_SCREEN })
|
||||
for (pages in listOf(connected, sessionDrawerPages(false))) {
|
||||
assertEquals(SessionDrawerPage.EFFECTS, pages.step(SessionDrawerPage.DISPLAY, 1))
|
||||
assertEquals(SessionDrawerPage.GAMES, pages.step(SessionDrawerPage.EFFECTS, 1))
|
||||
assertEquals(SessionDrawerPage.STEAMVR, pages.step(SessionDrawerPage.EFFECTS, 1))
|
||||
assertEquals(SessionDrawerPage.CARDBOARD, pages.step(SessionDrawerPage.STEAMVR, 1))
|
||||
assertEquals(SessionDrawerPage.GAMES, pages.step(SessionDrawerPage.CARDBOARD, 1))
|
||||
assertEquals(SessionDrawerPage.SESSION, pages.step(SessionDrawerPage.GAMES, 1))
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user