Skip to content

Commit 29232bd

Browse files
authored
Upgrade dev deps (#1778)
1 parent 351c68e commit 29232bd

File tree

96 files changed

+2539
-1789
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

96 files changed

+2539
-1789
lines changed

build.gradle.kts

+18-15
Original file line numberDiff line numberDiff line change
@@ -38,18 +38,20 @@ buildscript {
3838
}
3939

4040
apiValidation {
41-
ignoredProjects.addAll(listOf(
42-
"sentry-samples-android",
43-
"sentry-samples-console",
44-
"sentry-samples-jul",
45-
"sentry-samples-log4j2",
46-
"sentry-samples-logback",
47-
"sentry-samples-openfeign",
48-
"sentry-samples-servlet",
49-
"sentry-samples-spring",
50-
"sentry-samples-spring-boot",
51-
"sentry-samples-spring-boot-webflux"
52-
))
41+
ignoredProjects.addAll(
42+
listOf(
43+
"sentry-samples-android",
44+
"sentry-samples-console",
45+
"sentry-samples-jul",
46+
"sentry-samples-log4j2",
47+
"sentry-samples-logback",
48+
"sentry-samples-openfeign",
49+
"sentry-samples-servlet",
50+
"sentry-samples-spring",
51+
"sentry-samples-spring-boot",
52+
"sentry-samples-spring-boot-webflux"
53+
)
54+
)
5355
}
5456

5557
allprojects {
@@ -65,9 +67,10 @@ allprojects {
6567
testLogging.showStandardStreams = true
6668
testLogging.exceptionFormat = TestExceptionFormat.FULL
6769
testLogging.events = setOf(
68-
TestLogEvent.SKIPPED,
69-
TestLogEvent.PASSED,
70-
TestLogEvent.FAILED)
70+
TestLogEvent.SKIPPED,
71+
TestLogEvent.PASSED,
72+
TestLogEvent.FAILED
73+
)
7174
dependsOn("cleanTest")
7275
}
7376
withType<JavaCompile> {

buildSrc/src/main/java/Config.kt

+4-5
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ object Config {
1717
val springDependencyManagement = "io.spring.dependency-management"
1818
val springDependencyManagementVersion = "1.0.11.RELEASE"
1919
val gretty = "org.gretty"
20-
val grettyVersion = "3.0.5"
20+
val grettyVersion = "4.0.0"
2121
val gradleMavenPublishPlugin = "com.vanniktech:gradle-maven-publish-plugin:0.18.0"
2222
val dokkaPlugin = "org.jetbrains.dokka:dokka-gradle-plugin:$kotlinVersion"
2323
}
@@ -128,16 +128,15 @@ object Config {
128128
val minimumCoverage = BigDecimal.valueOf(0.6)
129129
}
130130
val spotless = "com.diffplug.spotless"
131-
val spotlessVersion = "5.12.5"
131+
val spotlessVersion = "5.17.0"
132132
val errorProne = "net.ltgt.errorprone"
133133
val errorpronePlugin = "net.ltgt.gradle:gradle-errorprone-plugin:2.0.1"
134134
val gradleVersionsPlugin = "com.github.ben-manes:gradle-versions-plugin:0.39.0"
135135
val gradleVersions = "com.github.ben-manes.versions"
136136
val detekt = "io.gitlab.arturbosch.detekt"
137-
// use RC2 to drop jcenter because of kotlinx-html
138-
val detektVersion = "1.17.1"
137+
val detektVersion = "1.18.1"
139138
val detektPlugin = "io.gitlab.arturbosch.detekt"
140-
val binaryCompatibilityValidatorVersion = "0.6.0"
139+
val binaryCompatibilityValidatorVersion = "0.7.1"
141140
val binaryCompatibilityValidatorPlugin = "org.jetbrains.kotlinx:binary-compatibility-validator:$binaryCompatibilityValidatorVersion"
142141
val binaryCompatibilityValidator = "org.jetbrains.kotlinx.binary-compatibility-validator"
143142
}

sentry-android-core/src/test/java/io/sentry/android/core/ActivityFramesTrackerTest.kt

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ import com.nhaarman.mockitokotlin2.any
88
import com.nhaarman.mockitokotlin2.mock
99
import com.nhaarman.mockitokotlin2.whenever
1010
import io.sentry.protocol.SentryId
11+
import org.junit.runner.RunWith
1112
import kotlin.test.Test
1213
import kotlin.test.assertEquals
1314
import kotlin.test.assertNull
14-
import org.junit.runner.RunWith
1515

1616
@RunWith(AndroidJUnit4::class)
1717
class ActivityFramesTrackerTest {

sentry-android-core/src/test/java/io/sentry/android/core/ActivityLifecycleIntegrationTest.kt

+33-18
Original file line numberDiff line numberDiff line change
@@ -141,12 +141,14 @@ class ActivityLifecycleIntegrationTest {
141141
val activity = mock<Activity>()
142142
sut.onActivityCreated(activity, fixture.bundle)
143143

144-
verify(fixture.hub).addBreadcrumb(check<Breadcrumb> {
145-
assertEquals("ui.lifecycle", it.category)
146-
assertEquals("navigation", it.type)
147-
assertEquals(SentryLevel.INFO, it.level)
148-
// cant assert data, its not a public API
149-
})
144+
verify(fixture.hub).addBreadcrumb(
145+
check<Breadcrumb> {
146+
assertEquals("ui.lifecycle", it.category)
147+
assertEquals("navigation", it.type)
148+
assertEquals(SentryLevel.INFO, it.level)
149+
// cant assert data, its not a public API
150+
}
151+
)
150152
}
151153

152154
@Test
@@ -261,9 +263,13 @@ class ActivityLifecycleIntegrationTest {
261263
val activity = mock<Activity>()
262264
sut.onActivityCreated(activity, fixture.bundle)
263265

264-
verify(fixture.hub).startTransaction(any(), check {
265-
assertEquals("ui.load", it)
266-
}, anyOrNull(), any(), any())
266+
verify(fixture.hub).startTransaction(
267+
any(),
268+
check {
269+
assertEquals("ui.load", it)
270+
},
271+
anyOrNull(), any(), any()
272+
)
267273
}
268274

269275
@Test
@@ -289,9 +295,12 @@ class ActivityLifecycleIntegrationTest {
289295
val activity = mock<Activity>()
290296
sut.onActivityCreated(activity, fixture.bundle)
291297

292-
verify(fixture.hub).startTransaction(check {
293-
assertEquals("Activity", it)
294-
}, any(), anyOrNull(), any(), any())
298+
verify(fixture.hub).startTransaction(
299+
check {
300+
assertEquals("Activity", it)
301+
},
302+
any(), anyOrNull(), any(), any()
303+
)
295304
}
296305

297306
@Test
@@ -344,9 +353,12 @@ class ActivityLifecycleIntegrationTest {
344353
sut.onActivityCreated(activity, fixture.bundle)
345354
sut.onActivityPostResumed(activity)
346355

347-
verify(fixture.hub).captureTransaction(check {
348-
assertEquals(SpanStatus.OK, it.status)
349-
}, anyOrNull())
356+
verify(fixture.hub).captureTransaction(
357+
check {
358+
assertEquals(SpanStatus.OK, it.status)
359+
},
360+
anyOrNull()
361+
)
350362
}
351363

352364
@Test
@@ -362,9 +374,12 @@ class ActivityLifecycleIntegrationTest {
362374

363375
sut.onActivityPostResumed(activity)
364376

365-
verify(fixture.hub).captureTransaction(check {
366-
assertEquals(SpanStatus.UNKNOWN_ERROR, it.status)
367-
}, anyOrNull())
377+
verify(fixture.hub).captureTransaction(
378+
check {
379+
assertEquals(SpanStatus.UNKNOWN_ERROR, it.status)
380+
},
381+
anyOrNull()
382+
)
368383
}
369384

370385
@Test

sentry-android-core/src/test/java/io/sentry/android/core/AndroidOptionsInitializerTest.kt

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ import io.sentry.SendCachedEnvelopeFireAndForgetIntegration
1717
import io.sentry.SentryLevel
1818
import io.sentry.SentryOptions
1919
import io.sentry.android.core.NdkIntegration.SENTRY_NDK_CLASS_NAME
20+
import org.junit.runner.RunWith
2021
import java.io.File
2122
import java.lang.RuntimeException
2223
import kotlin.test.BeforeTest
@@ -26,7 +27,6 @@ import kotlin.test.assertFalse
2627
import kotlin.test.assertNotNull
2728
import kotlin.test.assertNull
2829
import kotlin.test.assertTrue
29-
import org.junit.runner.RunWith
3030

3131
@RunWith(AndroidJUnit4::class)
3232
class AndroidOptionsInitializerTest {

sentry-android-core/src/test/java/io/sentry/android/core/AnrIntegrationTest.kt

+6-4
Original file line numberDiff line numberDiff line change
@@ -82,10 +82,12 @@ class AnrIntegrationTest {
8282

8383
sut.reportANR(fixture.hub, mock(), getApplicationNotResponding())
8484

85-
verify(fixture.hub).captureException(check {
86-
val ex = it as ExceptionMechanismException
87-
assertTrue(ex.isSnapshot)
88-
})
85+
verify(fixture.hub).captureException(
86+
check {
87+
val ex = it as ExceptionMechanismException
88+
assertTrue(ex.isSnapshot)
89+
}
90+
)
8991
}
9092

9193
private fun getApplicationNotResponding(): ApplicationNotResponding {

sentry-android-core/src/test/java/io/sentry/android/core/AppComponentsBreadcrumbsIntegrationTest.kt

+23-17
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,11 @@ import com.nhaarman.mockitokotlin2.whenever
1313
import io.sentry.Breadcrumb
1414
import io.sentry.IHub
1515
import io.sentry.SentryLevel
16+
import org.junit.runner.RunWith
1617
import java.lang.NullPointerException
1718
import kotlin.test.Test
1819
import kotlin.test.assertEquals
1920
import kotlin.test.assertFalse
20-
import org.junit.runner.RunWith
2121

2222
@RunWith(AndroidJUnit4::class)
2323
class AppComponentsBreadcrumbsIntegrationTest {
@@ -91,11 +91,13 @@ class AppComponentsBreadcrumbsIntegrationTest {
9191
val hub = mock<IHub>()
9292
sut.register(hub, options)
9393
sut.onLowMemory()
94-
verify(hub).addBreadcrumb(check<Breadcrumb> {
95-
assertEquals("device.event", it.category)
96-
assertEquals("system", it.type)
97-
assertEquals(SentryLevel.WARNING, it.level)
98-
})
94+
verify(hub).addBreadcrumb(
95+
check<Breadcrumb> {
96+
assertEquals("device.event", it.category)
97+
assertEquals("system", it.type)
98+
assertEquals(SentryLevel.WARNING, it.level)
99+
}
100+
)
99101
}
100102

101103
@Test
@@ -105,11 +107,13 @@ class AppComponentsBreadcrumbsIntegrationTest {
105107
val hub = mock<IHub>()
106108
sut.register(hub, options)
107109
sut.onTrimMemory(ComponentCallbacks2.TRIM_MEMORY_BACKGROUND)
108-
verify(hub).addBreadcrumb(check<Breadcrumb> {
109-
assertEquals("device.event", it.category)
110-
assertEquals("system", it.type)
111-
assertEquals(SentryLevel.WARNING, it.level)
112-
})
110+
verify(hub).addBreadcrumb(
111+
check<Breadcrumb> {
112+
assertEquals("device.event", it.category)
113+
assertEquals("system", it.type)
114+
assertEquals(SentryLevel.WARNING, it.level)
115+
}
116+
)
113117
}
114118

115119
@Test
@@ -129,11 +133,13 @@ class AppComponentsBreadcrumbsIntegrationTest {
129133
val hub = mock<IHub>()
130134
sut.register(hub, options)
131135
sut.onConfigurationChanged(mock())
132-
verify(hub).addBreadcrumb(check<Breadcrumb> {
133-
assertEquals("device.orientation", it.category)
134-
assertEquals("navigation", it.type)
135-
assertEquals(SentryLevel.INFO, it.level)
136-
// cant assert data, its not a public API
137-
})
136+
verify(hub).addBreadcrumb(
137+
check<Breadcrumb> {
138+
assertEquals("device.orientation", it.category)
139+
assertEquals("navigation", it.type)
140+
assertEquals(SentryLevel.INFO, it.level)
141+
// cant assert data, its not a public API
142+
}
143+
)
138144
}
139145
}

sentry-android-core/src/test/java/io/sentry/android/core/AppLifecycleIntegrationTest.kt

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@ import com.nhaarman.mockitokotlin2.any
55
import com.nhaarman.mockitokotlin2.mock
66
import com.nhaarman.mockitokotlin2.verify
77
import io.sentry.IHub
8+
import org.junit.runner.RunWith
89
import java.util.concurrent.CountDownLatch
910
import kotlin.test.Test
1011
import kotlin.test.assertNotNull
1112
import kotlin.test.assertNull
12-
import org.junit.runner.RunWith
1313

1414
@RunWith(AndroidJUnit4::class)
1515
class AppLifecycleIntegrationTest {

sentry-android-core/src/test/java/io/sentry/android/core/ConnectivityCheckerTest.kt

+16-8
Original file line numberDiff line numberDiff line change
@@ -61,28 +61,36 @@ class ConnectivityCheckerTest {
6161
fun `When network is active but not connected with permission, return NOT_CONNECTED for isConnected`() {
6262
whenever(networkInfo.isConnected).thenReturn(false)
6363

64-
assertEquals(ConnectivityChecker.Status.NOT_CONNECTED,
65-
ConnectivityChecker.getConnectionStatus(contextMock, mock()))
64+
assertEquals(
65+
ConnectivityChecker.Status.NOT_CONNECTED,
66+
ConnectivityChecker.getConnectionStatus(contextMock, mock())
67+
)
6668
}
6769

6870
@Test
6971
fun `When there's no permission, return NO_PERMISSION for isConnected`() {
7072
whenever(contextMock.checkPermission(any(), any(), any())).thenReturn(PERMISSION_DENIED)
7173

72-
assertEquals(ConnectivityChecker.Status.NO_PERMISSION,
73-
ConnectivityChecker.getConnectionStatus(contextMock, mock()))
74+
assertEquals(
75+
ConnectivityChecker.Status.NO_PERMISSION,
76+
ConnectivityChecker.getConnectionStatus(contextMock, mock())
77+
)
7478
}
7579

7680
@Test
7781
fun `When network is not active, return NOT_CONNECTED for isConnected`() {
78-
assertEquals(ConnectivityChecker.Status.NOT_CONNECTED,
79-
ConnectivityChecker.getConnectionStatus(contextMock, mock()))
82+
assertEquals(
83+
ConnectivityChecker.Status.NOT_CONNECTED,
84+
ConnectivityChecker.getConnectionStatus(contextMock, mock())
85+
)
8086
}
8187

8288
@Test
8389
fun `When ConnectivityManager is not available, return UNKNOWN for isConnected`() {
84-
assertEquals(ConnectivityChecker.Status.UNKNOWN,
85-
ConnectivityChecker.getConnectionStatus(mock(), mock()))
90+
assertEquals(
91+
ConnectivityChecker.Status.UNKNOWN,
92+
ConnectivityChecker.getConnectionStatus(mock(), mock())
93+
)
8694
}
8795

8896
@Test

sentry-android-core/src/test/java/io/sentry/android/core/ContextUtilsUnitTests.kt

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@ import android.content.Context
44
import androidx.test.core.app.ApplicationProvider
55
import androidx.test.ext.junit.runners.AndroidJUnit4
66
import com.nhaarman.mockitokotlin2.mock
7+
import org.junit.runner.RunWith
78
import kotlin.test.BeforeTest
89
import kotlin.test.Test
910
import kotlin.test.assertNotNull
1011
import kotlin.test.assertNull
11-
import org.junit.runner.RunWith
1212

1313
@RunWith(AndroidJUnit4::class)
1414
class ContextUtilsUnitTests {

sentry-android-core/src/test/java/io/sentry/android/core/DefaultAndroidEventProcessorTest.kt

+6-4
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ import io.sentry.protocol.SentryThread
2626
import io.sentry.protocol.SentryTransaction
2727
import io.sentry.protocol.User
2828
import io.sentry.test.getCtor
29+
import org.junit.runner.RunWith
2930
import kotlin.test.BeforeTest
3031
import kotlin.test.Test
3132
import kotlin.test.assertEquals
@@ -35,7 +36,6 @@ import kotlin.test.assertNotNull
3536
import kotlin.test.assertNull
3637
import kotlin.test.assertSame
3738
import kotlin.test.assertTrue
38-
import org.junit.runner.RunWith
3939

4040
@RunWith(AndroidJUnit4::class)
4141
class DefaultAndroidEventProcessorTest {
@@ -139,9 +139,11 @@ class DefaultAndroidEventProcessorTest {
139139
val sut = fixture.getSut(context)
140140

141141
val event = SentryEvent().apply {
142-
threads = mutableListOf(SentryThread().apply {
143-
id = 10L
144-
})
142+
threads = mutableListOf(
143+
SentryThread().apply {
144+
id = 10L
145+
}
146+
)
145147
}
146148

147149
assertNotNull(sut.process(event, null)) {

sentry-android-core/src/test/java/io/sentry/android/core/EnvelopeFileObserverIntegrationTest.kt

+1-2
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,14 @@ import androidx.test.ext.junit.runners.AndroidJUnit4
44
import com.nhaarman.mockitokotlin2.mock
55
import com.nhaarman.mockitokotlin2.verify
66
import io.sentry.Hub
7-
// import io.sentry.HubAdapter
87
import io.sentry.SentryOptions
8+
import org.junit.runner.RunWith
99
import java.io.File
1010
import java.nio.file.Files
1111
import kotlin.test.AfterTest
1212
import kotlin.test.BeforeTest
1313
import kotlin.test.Test
1414
import kotlin.test.assertEquals
15-
import org.junit.runner.RunWith
1615

1716
@RunWith(AndroidJUnit4::class)
1817
class EnvelopeFileObserverIntegrationTest {

0 commit comments

Comments
 (0)