Skip to content

Commit

Permalink
Fix/gradle cleanup (#129)
Browse files Browse the repository at this point in the history
* [fix] Allow getCookiesFromUrl to return empty string if no cookies are (#118)

returned  empty value from getCookie(url) instead of null

* [fix] Fix tests

* [fix] Remove key on doAfterNext

* [fix] Remove duplicated defaultConfig setup.

* [feature] Added new extension function List.nullIfEmpty().

* [feature] WGA-3519 : FragmentManager no longer nullable.

* [fix] NO_JIRA : Recycler view lib update.

* [fix] Roll back recyclerview update.

* #################################################

# |<----   Preferably using up to 50 chars   --->|<------------------->|
gradle files cleanup

# |<----   Try To Limit Each Line to a Maximum Of 72 Characters   ---->|
# Description - Explain why this change is being made

# |<----   Try To Limit Each Line to a Maximum Of 72 Characters   ---->|
# (Optional) Links to relevant tickets, articles or other resources
# Example: Crash from Firebase - www.xpto.com

#################################################
# |<----   Preferably using up to 50 chars   --->
# --- COMMIT END ---
# Tag can be
#    feature  (new feature)
#    fix      (bug/crash fix)
#    refactor (refactoring code)
#    style    (formatting, missing semi colons, etc; no code change)
#    doc      (changes to documentation)
#    test     (adding or refactoring tests; no production code change)
#    version  (version bump/new release; no production code change)
#    debug    (Changes in debugging code/frameworks; no production code change)
#    license  (Edits regarding licensing; no production code change)
#    hack     (Temporary fix to make things move forward; please avoid it)
#    WIP      (Work In Progress; for intermediate commits to keep patches reasonably sized)
#    defaults (changes default options)
#
# Note: Multiple tags can be combined, e.g. [fix][version] Fix issue X with methodhandles and bump to version 1.2.3
# --------------------
# Remember to:
#   * This can (should) use the title and description as the pull request
#   * Capitalize the subject line
#   * Use the imperative mood in the subject line
#   * Do not end the subject line with a period
#   * Separate subject from body with a blank line
#   * Use the body to explain what and why vs. how
#   * Can use multiple lines with "-" or "*" for bullet points in body
# --------------------

* Removed unused import

* Separated Collection utils from List utils

Co-authored-by: Pedro Belchior <[email protected]>
Co-authored-by: Belchior <[email protected]>
Co-authored-by: Guilherme Almeida <[email protected]>
Co-authored-by: Rita Ferreira <[email protected]>
  • Loading branch information
5 people authored Mar 20, 2020
1 parent 7d7eb31 commit 4cefb51
Show file tree
Hide file tree
Showing 10 changed files with 45 additions and 319 deletions.
28 changes: 1 addition & 27 deletions analytics-firebase/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -41,40 +41,14 @@ android {
testOptions {
unitTests.returnDefaultValues = true
}

configurations.all {
resolutionStrategy {

resolutionStrategy.force "com.google.guava:guava:$guavaVersion"
resolutionStrategy.force "com.google.code.findbugs:jsr305:$findBugsVersion"
resolutionStrategy.force "org.objenesis:objenesis:$objenesisVersion"

resolutionStrategy.force "net.bytebuddy:byte-buddy:$byteBuddyVersion"
resolutionStrategy.force "net.bytebuddy:byte-buddy-agent:$byteBuddyVersion"
resolutionStrategy.force "org.codehaus.plexus:plexus-utils:$plexusVersion"

// fail eagerly on version conflict (includes transitive dependencies)
// e.g. multiple different versions of the same dependency (group and name are equal)
failOnVersionConflict()
}
}
}

dependencies {

//Depends on Base Skeletoid
api project(path: ':base')

api ("com.google.firebase:firebase-core:$firebaseCoreVersion"){
exclude group: 'androidx.core', module: 'core'
exclude group: 'androidx.legacy', module: 'legacy-support-core-utils'
exclude group: 'androidx.legacy', module: 'legacy-support-core-ui'
exclude group: 'androidx.fragment', module: 'fragment'
exclude group: 'androidx.annotation', module: 'annotation'
exclude group: 'com.google.android.gms', module: 'play-services-basement'
exclude group: 'com.google.firebase', module: 'firebase-common'

}
api ("com.google.firebase:firebase-core:$firebaseCoreVersion")

testImplementation project(path: ':base', configuration: 'childTestDependencies')
}
24 changes: 1 addition & 23 deletions analytics-ga/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -28,22 +28,6 @@ android {
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}

configurations.all {
resolutionStrategy {
resolutionStrategy.force "com.google.guava:guava:$guavaVersion"
resolutionStrategy.force "com.google.code.findbugs:jsr305:$findBugsVersion"
resolutionStrategy.force "org.objenesis:objenesis:$objenesisVersion"

resolutionStrategy.force "net.bytebuddy:byte-buddy:$byteBuddyVersion"
resolutionStrategy.force "net.bytebuddy:byte-buddy-agent:$byteBuddyVersion"
resolutionStrategy.force "org.codehaus.plexus:plexus-utils:$plexusVersion"

// fail eagerly on version conflict (includes transitive dependencies)
// e.g. multiple different versions of the same dependency (group and name are equal)
failOnVersionConflict()
}
}
}

dependencies {
Expand All @@ -53,11 +37,5 @@ dependencies {

testImplementation project(path: ':base', configuration: 'childTestDependencies')

implementation ("com.google.android.gms:play-services-analytics:$playServicesAnalytics"){
exclude group: 'androidx.annotation', module: 'annotation'
exclude group: 'androidx.fragment', module: 'fragment'
exclude group: 'androidx.core', module: 'core'
exclude group: 'androidx.legacy', module: 'legacy-support-core-utils'
exclude group: 'androidx.legacy', module: 'legacy-support-core-ui'
}
implementation ("com.google.android.gms:play-services-analytics:$playServicesAnalytics")
}
4 changes: 1 addition & 3 deletions apprating/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,5 @@ dependencies {
testImplementation "org.powermock:powermock-module-junit4-rule:$rootProject.powermockVersion"
testImplementation "org.powermock:powermock-api-mockito2:$rootProject.powermockVersion"
testImplementation "org.powermock:powermock-classloading-xstream:$rootProject.powermockVersion"
testImplementation("org.robolectric:robolectric:$rootProject.robolectricVersion") {
exclude group: 'com.thoughtworks.xstream', module: 'xstream'
}
testImplementation("org.robolectric:robolectric:$rootProject.robolectricVersion")
}
56 changes: 8 additions & 48 deletions base/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -49,24 +49,6 @@ android {
configurations {
childTestDependencies.extendsFrom testImplementation
}

configurations.all {

resolutionStrategy {
resolutionStrategy.force "com.google.guava:guava:$guavaVersion"
resolutionStrategy.force "com.google.code.findbugs:jsr305:$findBugsVersion"

resolutionStrategy.force "org.objenesis:objenesis:$objenesisVersion"
resolutionStrategy.force "net.bytebuddy:byte-buddy:$byteBuddyVersion"
resolutionStrategy.force "net.bytebuddy:byte-buddy-agent:$byteBuddyVersion"

// fail eagerly on version conflict (includes transitive dependencies)
// e.g. multiple different versions of the same dependency (group and name are equal)
failOnVersionConflict()
}

resolutionStrategy.force "org.codehaus.plexus:plexus-utils:$plexusVersion"
}
}

dependencies {
Expand All @@ -75,51 +57,29 @@ dependencies {

api "androidx.annotation:annotation:$appcompatVersion"

implementation ("androidx.loader:loader:$loaderVersion") {
exclude group: 'androidx.annotation', module: 'annotation'
exclude group: 'androidx.core', module: 'core'
}
implementation ("androidx.loader:loader:$loaderVersion")

implementation ("androidx.vectordrawable:vectordrawable-animated:$vectorDrawableVersion") {
exclude group: 'androidx.annotation', module: 'annotation'
exclude group: 'androidx.vectordrawable', module: 'vectordrawable'
}
implementation ("androidx.vectordrawable:vectordrawable-animated:$vectorDrawableVersion")

implementation ("androidx.legacy:legacy-support-core-utils:$androidLegacyVersion") {
exclude group: 'android.loader', module: 'loader'
exclude group: 'androidx.annotation', module: 'annotation'
exclude group: 'androidx.core', module:'core'
}
implementation ("androidx.legacy:legacy-support-core-utils:$androidLegacyVersion")

implementation ("androidx.appcompat:appcompat:$appcompatVersion") {
exclude group: 'androidx.vectordrawable', module: 'vectordrawable-animated'
exclude group: 'androidx.annotation', module: 'annotation'
exclude group: 'androidx.core', module:'core'
}
implementation ("androidx.appcompat:appcompat:$appcompatVersion")

api "io.reactivex.rxjava2:rxjava:$rxJavaVersion"
api ("io.reactivex.rxjava2:rxandroid:$rxAndroidVersion"){
exclude group: 'io.reactivex.rxjava2', module: 'rxjava'
}
api ("io.reactivex.rxjava2:rxandroid:$rxAndroidVersion")

testImplementation "org.jetbrains.kotlin:kotlin-test:$kotlinVersion"

testImplementation "junit:junit:$junitVersion"
testImplementation "org.jetbrains.kotlin:kotlin-test:$rootProject.kotlinVersion"
testImplementation ("org.mockito:mockito-core:$mockitoVersion")

testImplementation ("org.powermock:powermock-module-junit4:$powermockVersion") {
exclude group: 'org.mockito', module: 'mockito-core'
}
testImplementation ("org.powermock:powermock-module-junit4:$powermockVersion")
testImplementation ("org.powermock:powermock-module-junit4-rule:$powermockVersion")

testImplementation ("org.powermock:powermock-api-mockito2:$powermockVersion") {
exclude group: 'org.mockito', module: 'mockito-core'
}
testImplementation ("org.powermock:powermock-api-mockito2:$powermockVersion")
testImplementation "org.powermock:powermock-classloading-xstream:$powermockVersion"
testImplementation ("org.robolectric:robolectric:$robolectricVersion") {
exclude group: 'androidx.annotation', module: 'annotation'
}
testImplementation ("org.robolectric:robolectric:$robolectricVersion")
}

apply from: "../jacoco.gradle"
Expand Down
44 changes: 6 additions & 38 deletions kt-extensions/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -39,56 +39,24 @@ android {
testOptions {
unitTests.returnDefaultValues = true
}

configurations.all {
resolutionStrategy {
resolutionStrategy.force "com.google.guava:guava:$guavaVersion"
resolutionStrategy.force "com.google.code.findbugs:jsr305:$findBugsVersion"

resolutionStrategy.force "org.objenesis:objenesis:$objenesisVersion"
resolutionStrategy.force "net.bytebuddy:byte-buddy:$byteBuddyVersion"
resolutionStrategy.force "net.bytebuddy:byte-buddy-agent:$byteBuddyVersion"
resolutionStrategy.force "org.codehaus.plexus:plexus-utils:$plexusVersion"

failOnVersionConflict()
}
}
}

dependencies {

implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlinVersion"

implementation ("androidx.vectordrawable:vectordrawable-animated:$vectorDrawableVersion") {
exclude group: 'androidx.vectordrawable', module: 'vectordrawable'
}
implementation ("androidx.vectordrawable:vectordrawable-animated:$vectorDrawableVersion")

implementation ("androidx.legacy:legacy-support-core-utils:$androidLegacyVersion") {
exclude group: 'android.loader', module: 'loader'
exclude group: 'androidx.annotation', module: 'annotation'
exclude group: 'androidx.core', module:'core'
}
implementation ("androidx.legacy:legacy-support-core-utils:$androidLegacyVersion")

implementation ("androidx.appcompat:appcompat:$appcompatVersion") {
exclude group: 'androidx.vectordrawable', module: 'vectordrawable-animated'
exclude group: 'androidx.annotation', module: 'annotation'
exclude group: 'androidx.core', module:'core'
exclude group: 'androidx.fragment', module: 'fragment'
}
implementation ("androidx.appcompat:appcompat:$appcompatVersion")

testImplementation "junit:junit:$junitVersion"
testImplementation "org.jetbrains.kotlin:kotlin-test:$rootProject.kotlinVersion"
testImplementation "org.mockito:mockito-core:$mockitoVersion"
testImplementation ("org.powermock:powermock-module-junit4:$powermockVersion") {
exclude group: 'org.mockito', module: 'mockito-core'
}
testImplementation ("org.powermock:powermock-module-junit4:$powermockVersion")
testImplementation "org.powermock:powermock-module-junit4-rule:$powermockVersion"
testImplementation ("org.powermock:powermock-api-mockito2:$powermockVersion") {
exclude group: 'org.mockito', module: 'mockito-core'
}
testImplementation ("org.powermock:powermock-api-mockito2:$powermockVersion")
testImplementation "org.powermock:powermock-classloading-xstream:$powermockVersion"
testImplementation ("org.robolectric:robolectric:$robolectricVersion") {
exclude group: 'androidx.annotation', module: 'annotation'
exclude group: 'com.thoughtworks.xstream', module: 'xstream'
}
testImplementation ("org.robolectric:robolectric:$robolectricVersion")
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
package com.mindera.skeletoid.kt.extensions.utils

fun <T: Any> List<T>.nullIfEmpty(): List<T>? {
return if (isEmpty()) null else this
}
29 changes: 3 additions & 26 deletions performance-firebase/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -44,22 +44,6 @@ android {
testOptions {
unitTests.returnDefaultValues = true
}

configurations.all {
resolutionStrategy {
resolutionStrategy.force "com.google.guava:guava:$guavaVersion"
resolutionStrategy.force "com.google.code.findbugs:jsr305:$findBugsVersion"
resolutionStrategy.force "org.objenesis:objenesis:$objenesisVersion"

resolutionStrategy.force "net.bytebuddy:byte-buddy:$byteBuddyVersion"
resolutionStrategy.force "net.bytebuddy:byte-buddy-agent:$byteBuddyVersion"
resolutionStrategy.force "org.codehaus.plexus:plexus-utils:$plexusVersion"

// fail eagerly on version conflict (includes transitive dependencies)
// e.g. multiple different versions of the same dependency (group and name are equal)
failOnVersionConflict()
}
}
}

dependencies {
Expand All @@ -69,16 +53,9 @@ dependencies {
api project(path: ':base')
testImplementation project(path: ':base', configuration: 'childTestDependencies')

api("com.google.firebase:firebase-perf:$firebasePerfVersion") {
exclude group: 'androidx.annotation', module: 'annotation'
exclude group: 'androidx.legacy', module: 'legacy-support-v4'
}
api("com.google.firebase:firebase-perf:$firebasePerfVersion")

androidTestImplementation("androidx.test:runner:$testRunnerVersion") {
exclude group: 'androidx.annotation', module: 'annotation'
}
androidTestImplementation("androidx.test:runner:$testRunnerVersion")

androidTestImplementation("androidx.test.espresso:espresso-core:$espressoVersion") {
exclude group: 'androidx.annotation', module: 'annotation'
}
androidTestImplementation("androidx.test.espresso:espresso-core:$espressoVersion")
}
Loading

0 comments on commit 4cefb51

Please sign in to comment.