Hopefully fixed SDK-issue on Bitrise now.

This commit is contained in:
Alexander Pacha
2017-01-17 23:59:09 +01:00
parent d76f879d34
commit 9c0f3bb4af
4 changed files with 17 additions and 12 deletions

View File

@@ -7,16 +7,16 @@ android:
- tools - tools
# The BuildTools version used by your project # The BuildTools version used by your project
- build-tools-24.0.2 - build-tools-25.0.2
# The SDK version used to compile your project # The SDK version used to compile your project
- android-24 - android-25
# Additional components # Additional components
- extra-google-google_play_services - extra-google-google_play_services
- extra-google-m2repository - extra-google-m2repository
- extra-android-m2repository - extra-android-m2repository
- sys-img-armeabi-v7a-android-24 - sys-img-armeabi-v7a-android-25
before_script: before_script:
# Create and start emulator # Create and start emulator
@@ -26,4 +26,4 @@ before_script:
# - adb shell input keyevent 82 & # - adb shell input keyevent 82 &
script: ./gradlew assembleRelease script: ./gradlew assembleRelease
#connectedAndroidTest #connectedAndroidTest

View File

@@ -6,13 +6,13 @@ def code = formattedDate.toInteger() * 10000
def buildNumber = System.getenv("BITRISE_BUILD_NUMBER") as Integer ?: 0 def buildNumber = System.getenv("BITRISE_BUILD_NUMBER") as Integer ?: 0
android { android {
compileSdkVersion 24 compileSdkVersion 25
buildToolsVersion "24.0.2" buildToolsVersion "25.0.2"
defaultConfig { defaultConfig {
applicationId "org.hitlabnz.sensor_fusion_demo" applicationId "org.hitlabnz.sensor_fusion_demo"
minSdkVersion 18 minSdkVersion 18
targetSdkVersion 24 targetSdkVersion 25
versionCode code + buildNumber versionCode code + buildNumber
versionName "1.4." + buildNumber versionName "1.4." + buildNumber
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
@@ -31,12 +31,12 @@ android {
} }
dependencies { dependencies {
compile 'com.android.support:support-v4:24.2.1' compile 'com.android.support:support-v4:25.0.1'
testCompile 'junit:junit:4.12' testCompile 'junit:junit:4.12'
testCompile 'org.mockito:mockito-core:1.10.19' testCompile 'org.mockito:mockito-core:2.2.27'
androidTestCompile 'com.android.support:support-annotations:24.2.1' androidTestCompile 'com.android.support:support-annotations:25.0.1'
androidTestCompile 'org.hamcrest:hamcrest-library:1.3' androidTestCompile 'org.hamcrest:hamcrest-library:1.3'
androidTestCompile 'com.android.support.test.uiautomator:uiautomator-v18:2.1.2' androidTestCompile 'com.android.support.test.uiautomator:uiautomator-v18:2.1.2'

View File

@@ -1,6 +1,7 @@
package org.hitlabnz.sensor_fusion_demo.androidTest; package org.hitlabnz.sensor_fusion_demo.androidTest;
import android.app.Application; import android.app.Application;
import android.support.test.espresso.NoMatchingViewException;
import android.support.test.espresso.matcher.ViewMatchers; import android.support.test.espresso.matcher.ViewMatchers;
import android.support.test.rule.ActivityTestRule; import android.support.test.rule.ActivityTestRule;
import android.support.test.runner.AndroidJUnit4; import android.support.test.runner.AndroidJUnit4;
@@ -61,6 +62,10 @@ public class ApplicationTest {
} }
public static void DiscardGyroscopeWarning() { public static void DiscardGyroscopeWarning() {
onView(withText("OK")).perform(click()); try {
onView(withText("OK")).perform(click());
} catch (NoMatchingViewException e) {
//view not displayed logic
}
} }
} }

View File

@@ -7,7 +7,7 @@ buildscript {
maven { url 'http://repo1.maven.org/maven2' } maven { url 'http://repo1.maven.org/maven2' }
} }
dependencies { dependencies {
classpath 'com.android.tools.build:gradle:2.2.0' classpath 'com.android.tools.build:gradle:2.2.2'
classpath 'com.github.ben-manes:gradle-versions-plugin:0.13.0' classpath 'com.github.ben-manes:gradle-versions-plugin:0.13.0'
} }
} }