Skip to content

Commit

Permalink
use creds from env
Browse files Browse the repository at this point in the history
  • Loading branch information
Kerem Beygo committed Oct 29, 2024
1 parent 188d4c4 commit ea67028
Showing 1 changed file with 2 additions and 11 deletions.
13 changes: 2 additions & 11 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ android {
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
testInstrumentationRunnerArguments clearPackageData: 'true'

buildConfigField "String", "SAUCE_USERNAME", getProperty("SAUCE_USERNAME", "\"\"")
buildConfigField "String", "SAUCE_ACCESS_KEY", getProperty("SAUCE_ACCESS_KEY", "\"\"")
buildConfigField "String", "SAUCE_USERNAME", "\"${System.getenv('SAUCE_USERNAME')}\""
buildConfigField "String", "SAUCE_ACCESS_KEY", "\"${System.getenv('SAUCE_ACCESS_KEY')}\""
}

testOptions {
Expand Down Expand Up @@ -64,15 +64,6 @@ android {
}
}

String getProperty(String name, String defaultValue) {
if (!rootProject.file("./local.properties").exists()) {
return defaultValue
}
def properties = new Properties()
properties.load(rootProject.file("./local.properties").newDataInputStream())
return properties.containsKey(name) ? properties[name] : defaultValue
}

task jacocoTestReport(type: JacocoReport, dependsOn: ['testDebugUnitTest', 'createDebugCoverageReport']) {

reports {
Expand Down

0 comments on commit ea67028

Please sign in to comment.