Skip to content
This repository has been archived by the owner on Dec 7, 2019. It is now read-only.

Read external storage variable for downloading screenshots #168

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions composer/src/main/kotlin/com/gojuno/composer/TestRun.kt
Original file line number Diff line number Diff line change
Expand Up @@ -165,12 +165,15 @@ private fun pullTestFiles(adbDevice: AdbDevice, test: InstrumentationTest, outpu
}
.flatMap { screenshotsFolderOnHostMachine ->
adbDevice
.pullFolder(
.externalStorage()
.flatMap { externalStorageFolder ->
adbDevice.pullFolder(
// TODO: Add support for internal storage and external storage strategies.
folderOnDevice = "/storage/emulated/0/app_spoon-screenshots/${test.className}/${test.testName}",
folderOnDevice = "$externalStorageFolder/app_spoon-screenshots/${test.className}/${test.testName}",
folderOnHostMachine = screenshotsFolderOnHostMachine,
logErrors = verboseOutput
)
)
}
.map { File(screenshotsFolderOnHostMachine, test.testName) }
}
.map { screenshotsFolderOnHostMachine ->
Expand Down
2 changes: 1 addition & 1 deletion dependencies.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ ext.versions = [

rxJava : '1.3.0',
jCommander : '1.71',
commander : '0.1.7',
commander : '0.1.9',
apacheCommonsIo : '2.5',
apacheCommonsLang: '3.5',
gson : '2.8.0',
Expand Down