mirror of
https://github.com/Droid-Deck/DroidDeck.git
synced 2026-11-19 12:56:06 +00:00
test(session): skip the /mnt view comparison on hosts where /mnt is a symlink (#2806)
rawAndStorageMountViewsOverlapButDistinctFoldersDoNot canonicalizes /mnt/media_rw/... with the host JVM. On SteamOS and Fedora Atomic /mnt is a symlink to var/mnt, so the path resolves to /var/mnt/media_rw/..., which no Android device produces, and the unit suite fails there. Skip the case when the host's /mnt is a symlink.
This commit is contained in:
1 parent
0a8d6669bf
commit
ca7b7e74ec
1 file changed
+2
@@ -4,6 +4,7 @@ import com.droiddeck.launcher.frontend.AddedGames
|
||||
import com.droiddeck.launcher.frontend.Library
|
||||
import java.io.File
|
||||
import org.junit.Assert.*
|
||||
import org.junit.Assume.assumeFalse
|
||||
import org.junit.Rule
|
||||
import org.junit.Test
|
||||
import org.junit.rules.TemporaryFolder
|
||||
@@ -145,6 +146,7 @@ class SteamLibrariesTest {
|
||||
}
|
||||
|
||||
@Test fun rawAndStorageMountViewsOverlapButDistinctFoldersDoNot() {
|
||||
assumeFalse(java.nio.file.Files.isSymbolicLink(File("/mnt").toPath()))
|
||||
val raw = SteamLibraries.canonical(File("/mnt/media_rw/ABCD-1234/Games"))
|
||||
val storage = SteamLibraries.canonical(File("/storage/ABCD-1234/Games"))
|
||||
assertEquals(storage, raw)
|
||||
|
||||
Reference in new issue
Block a user