From 2367ed5d42f73d5b33a827f3697923f33eac07f9 Mon Sep 17 00:00:00 2001 From: Ishan Pansuriya Date: Fri, 13 Oct 2023 13:04:21 -0400 Subject: [PATCH] Revert "Assertion arguments should be passed in the correct order" --- build.gradle | 27 +------------------ gradle.properties | 3 --- gradle/wrapper/gradle-wrapper.properties | 3 +-- .../settings/PreferencesUtilsTest.java | 8 +++--- 4 files changed, 6 insertions(+), 35 deletions(-) diff --git a/build.gradle b/build.gradle index eaea30fd7..0e9d2bbef 100644 --- a/build.gradle +++ b/build.gradle @@ -1,17 +1,12 @@ apply plugin: 'com.android.application' buildscript { - ext { - agp_version = '8.1.1' - } repositories { google() mavenCentral() } dependencies { - classpath "com.android.tools.build:gradle:$agp_version" - classpath "org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:2.7.1" - + classpath 'com.android.tools.build:gradle:8.2.0-beta01' } } @@ -22,26 +17,6 @@ allprojects { } } -apply plugin: "org.sonarqube" - -sonarqube { - properties { - property "sonar.projectName", "OpenTracksConcordia" - property "sonar.projectKey", "OpenTracksConcordia" - property "sonar.tests", ["src/androidTest/java"] - property "sonar.test.inclusions", "*/*Test/**" - property "sonar.sourceEncoding", "UTF-8" - property "sonar.sources", "src/main/java" - property "sonar.exclusions", '*/*Test/**,' + - '*.json,' + - '*/*test/**,' + - '**/.gradle/**,' + - '**/R.class' - } -} - - - def getVersionName = { -> try { def stdout = new ByteArrayOutputStream() diff --git a/gradle.properties b/gradle.properties index 08a446e9f..3c8ba69b7 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,5 +1,2 @@ android.useAndroidX=true org.gradle.jvmargs=-Xmx1024m -systemProp.sonar.host.url=http://localhost:9000 -systemProp.sonar.login=sqp_61650630da8d6ff10b29db5c39ba42ef7feed25e - diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 47194dbbe..ac72c34e8 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,7 +1,6 @@ -#Sun Oct 08 22:27:07 EDT 2023 distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip networkTimeout=10000 validateDistributionUrl=true zipStoreBase=GRADLE_USER_HOME diff --git a/src/androidTest/java/de/dennisguse/opentracks/settings/PreferencesUtilsTest.java b/src/androidTest/java/de/dennisguse/opentracks/settings/PreferencesUtilsTest.java index 4bc94e361..adb806d00 100644 --- a/src/androidTest/java/de/dennisguse/opentracks/settings/PreferencesUtilsTest.java +++ b/src/androidTest/java/de/dennisguse/opentracks/settings/PreferencesUtilsTest.java @@ -309,11 +309,11 @@ public void testEditCustomLayout() { // then only updated profile is modified in the custom layouts List layoutsAfter = PreferencesUtils.getAllCustomLayouts(); - assertEquals(2, layoutsBefore.size()); - assertEquals(2, layoutsAfter.size()); + assertEquals(layoutsBefore.size(), 2); + assertEquals(layoutsAfter.size(), 2); - assertEquals(4, layoutsBefore.get(0).getFields().stream().filter(DataField::isVisible).count()); - assertEquals(1, layoutsAfter.get(0).getFields().stream().filter(DataField::isVisible).count()); + assertEquals(layoutsBefore.get(0).getFields().stream().filter(DataField::isVisible).count(), 4); + assertEquals(layoutsAfter.get(0).getFields().stream().filter(DataField::isVisible).count(), 1); } @Test