Skip to content

Commit

Permalink
Remove transitive dependency to realm-android-library in order to sup…
Browse files Browse the repository at this point in the history
…port realm-android-library-object-server (#66)

* Remove transitive dependency to realm-android-library in order to support realm-android-library-object-server

* move androidTests to tests project in order to apply Realm plugin

* update Jenkinsfile

* fix error
  • Loading branch information
zaki50 committed Oct 12, 2016
1 parent f423274 commit 4a9d94a
Show file tree
Hide file tree
Showing 15 changed files with 61 additions and 11 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
@@ -1,3 +1,9 @@
## 1.3.1

### Bug fixes

* Removed transitive dependency to realm-android-library in order to support realm-android-library-object-server.

## 1.3.0

### Enhancements
Expand Down
4 changes: 2 additions & 2 deletions Jenkinsfile
Expand Up @@ -25,7 +25,7 @@ try {
buildEnv.inside("-e HOME=/tmp -e _JAVA_OPTIONS=-Duser.home=/tmp --privileged -v /dev/bus/usb:/dev/bus/usb -v ${env.HOME}/gradle-cache:/tmp/.gradle -v ${env.HOME}/.android:/tmp/.android -v ${env.HOME}/ccache:/tmp/.ccache") {
stage('Build & Test') {
try {
gradle 'javadoc check connectedCheck'
gradle 'assemble javadoc check connectedCheck'
if (env.BRANCH_NAME == 'master') {
stage('Collect metrics') {
collectAarMetrics()
Expand Down Expand Up @@ -109,4 +109,4 @@ def gradle(String commands) {

def gradle(String relativePath, String commands) {
sh "cd ${relativePath} && chmod +x gradlew && ./gradlew ${commands} --stacktrace"
}
}
11 changes: 3 additions & 8 deletions adapters/build.gradle
Expand Up @@ -6,7 +6,6 @@ apply plugin: 'com.jfrog.bintray'
apply plugin: 'findbugs'
apply plugin: 'pmd'
apply plugin: 'checkstyle'
apply plugin: 'realm-android'

android {
compileSdkVersion rootProject.sdkVersion
Expand All @@ -16,16 +15,12 @@ android {
minSdkVersion 9
targetSdkVersion rootProject.sdkVersion
project.archivesBaseName = "android-adapters"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
}

dependencies {
compile 'com.android.support:recyclerview-v7:24.2.1'

androidTestCompile 'com.android.support.test:runner:0.5'
androidTestCompile 'com.android.support.test:rules:0.5'
androidTestCompile 'junit:junit:4.12'
provided "com.android.support:recyclerview-v7:${supportLibraryVersion}"
provided "io.realm:realm-android-library:${realmVersion}"
}

task findbugs(type: FindBugs) {
Expand Down Expand Up @@ -194,4 +189,4 @@ artifacts {
afterEvaluate {
javadoc.classpath += project.files(android.getBootClasspath().join(File.pathSeparator))
javadoc.classpath += project.android.libraryVariants.toList().first().javaCompile.classpath
}
}
1 change: 1 addition & 0 deletions build.gradle
Expand Up @@ -2,6 +2,7 @@ apply plugin: 'ch.netzwerg.release'
project.ext.sdkVersion = 24
project.ext.buildTools = '24.0.3'
project.ext.realmVersion = '2.0.2'
project.ext.supportLibraryVersion = '24.2.1'

buildscript {
repositories {
Expand Down
3 changes: 2 additions & 1 deletion example/build.gradle
Expand Up @@ -25,5 +25,6 @@ android {

dependencies {
compile project(':adapters')
compile 'com.android.support:appcompat-v7:24.2.1'
compile "com.android.support:appcompat-v7:${supportLibraryVersion}"
compile "com.android.support:recyclerview-v7:${supportLibraryVersion}"
}
1 change: 1 addition & 0 deletions settings.gradle
@@ -1,2 +1,3 @@
include 'adapters'
include 'tests'
include 'example'
43 changes: 43 additions & 0 deletions tests/build.gradle
@@ -0,0 +1,43 @@
apply plugin: 'com.android.library'
apply plugin: 'checkstyle'
apply plugin: 'realm-android'

android {
compileSdkVersion rootProject.sdkVersion
buildToolsVersion rootProject.buildTools

defaultConfig {
minSdkVersion 9
targetSdkVersion rootProject.sdkVersion
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
}

dependencies {
compile project(':adapters')

androidTestCompile "com.android.support:recyclerview-v7:${supportLibraryVersion}"
androidTestCompile "io.realm:realm-android-library:${realmVersion}"
androidTestCompile 'com.android.support.test:runner:0.5'
androidTestCompile 'com.android.support.test:rules:0.5'
androidTestCompile 'junit:junit:4.12'
}

task checkstyle(type: Checkstyle) {
group = 'Test'

source 'src'
include '**/*.java'
exclude '**/gen/**'
exclude '**/R.java'
exclude '**/BuildConfig.java'

def configProps = ['proj.module.dir': projectDir.absolutePath]
configProperties configProps

configFile = file("${projectDir}/../config/checkstyle/checkstyle.xml")

// empty classpath
classpath = files()
}

3 changes: 3 additions & 0 deletions tests/src/main/AndroidManifest.xml
@@ -0,0 +1,3 @@
<manifest package="io.realm.android.tests">

</manifest>

0 comments on commit 4a9d94a

Please sign in to comment.