Skip to content
This repository was archived by the owner on Aug 30, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
7bbbe08
ref: fix test linting (#491)
marandaneto Jul 23, 2020
95cc5f4
fix: event.level fatal is not a crashed session (#492)
marandaneto Jul 23, 2020
50a2165
feat: drop store endpoint in favor of envelope (#490)
marandaneto Jul 24, 2020
2f3b563
fix: ktlint for kts files (#493)
marandaneto Jul 24, 2020
29fbcc7
sentry-java readme
bruno-garcia Jul 27, 2020
14a5e29
feat: rotate cache folder (#494)
marandaneto Jul 28, 2020
db5345b
Merge remote-tracking branch 'origin' into feat/sentry-java
maciejwalkowiak Jul 29, 2020
ad2e0d8
make EventProcessor.process Nullable (#507)
davemt Aug 5, 2020
707015f
Merge remote-tracking branch 'origin/master' into feat/sentry-java
maciejwalkowiak Aug 11, 2020
acfb973
Merge remote-tracking branch 'origin/master' into feat/sentry-java
maciejwalkowiak Aug 12, 2020
9607fea
fix merge conflict
marandaneto Aug 13, 2020
d18da36
Add Logback integration. (#511)
maciejwalkowiak Aug 20, 2020
d14445a
Merge branch 'master' into 3.0.0
marandaneto Aug 26, 2020
68c7ceb
Sentry Spring Boot Starter. (#517)
maciejwalkowiak Aug 27, 2020
2d6e215
Refactor binding options (#530)
maciejwalkowiak Aug 29, 2020
0a8bde6
Add `sendDefaultPii` flag to `SentryOptions`. (#531)
maciejwalkowiak Aug 30, 2020
82e4efe
Attach breadcrumbs to events triggered in Logback integration. (#532)
maciejwalkowiak Aug 31, 2020
944f478
Bump to 3.0.0-alpha.1 (#535)
marandaneto Sep 1, 2020
eefdd31
feat: enable release health by default (#534)
marandaneto Sep 1, 2020
df08324
Merge branch 'master' into 3.0.0
marandaneto Sep 2, 2020
35750dd
Add Log4j2 integration. (#537)
maciejwalkowiak Sep 2, 2020
3737aab
feat: session updates along with the event (#514)
marandaneto Sep 3, 2020
cd6f526
Merge remote-tracking branch 'origin/master' into feat/sentry-java
maciejwalkowiak Sep 3, 2020
3915ca4
fix: enable session tracking by default on sample (#538)
marandaneto Sep 3, 2020
9aad2cb
chore 3.0.0-alpha.1
marandaneto Sep 3, 2020
e767af6
prepare: 3.0.0-alpha.2
marandaneto Sep 3, 2020
b754303
Bump Gradle to 6.6.1
marandaneto Sep 3, 2020
60af521
Extract minimum required coverage by Jacoco plugin. (#541)
maciejwalkowiak Sep 4, 2020
799e581
Merge branch 'master' into 3.0.0
marandaneto Sep 4, 2020
923f9fc
Add Spring Integration. (#539)
maciejwalkowiak Sep 8, 2020
7845eb8
Merge branch '3.0.0' into feat/sentry-java
bruno-garcia Sep 8, 2020
89b7606
fix conflicts
marandaneto Sep 9, 2020
ed1b133
Merge branch 'master' into 3.0.0
marandaneto Sep 9, 2020
33766f4
ref: move init flag (#542)
marandaneto Sep 9, 2020
c891d6a
fix: Asserting events on Envelope sent to Transport (#548)
maciejwalkowiak Sep 9, 2020
ae0219d
Add option to set user information via `SentryUserProvider` (#549)
maciejwalkowiak Sep 9, 2020
cdb4530
Merge branch '3.0.0' into feat/sentry-java
bruno-garcia Sep 9, 2020
6d02f98
upgrade cache id
marandaneto Sep 10, 2020
dd0e7d8
Feat/sentry java fix kotlin (#552)
maciejwalkowiak Sep 10, 2020
188ef14
ref: sentry-core to sentry (#553)
bruno-garcia Sep 10, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
ref: fix test linting (#491)
  • Loading branch information
marandaneto authored Jul 23, 2020
commit 7bbbe08ce71cbb0a0e96c60dc29b5f7028a498fc
32 changes: 16 additions & 16 deletions sentry-core/src/test/java/io/sentry/core/DiagnosticLoggerTest.kt
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class DiagnosticLoggerTest {

@Test
fun `when debug is true and level is set to null, a call to log does not throw`() {
fixture.options!!.setDiagnosticLevel(null)
fixture.options.setDiagnosticLevel(null)
fixture.getSut().log(SentryLevel.DEBUG, expectedMessage)
}

Expand All @@ -61,7 +61,7 @@ class DiagnosticLoggerTest {

@Test
fun `when debug is true and option level is info, a call to log and level debug is not logged`() {
fixture.options!!.setDiagnosticLevel(SentryLevel.INFO)
fixture.options.setDiagnosticLevel(SentryLevel.INFO)
val sut = fixture.getSut()
val expectedLevel = SentryLevel.DEBUG
sut.log(expectedLevel, expectedMessage)
Expand All @@ -70,7 +70,7 @@ class DiagnosticLoggerTest {

@Test
fun `when debug is true and option level is error, a call to log and level fatal is logged`() {
fixture.options!!.setDiagnosticLevel(SentryLevel.ERROR)
fixture.options.setDiagnosticLevel(SentryLevel.ERROR)
val sut = fixture.getSut()
val expectedLevel = SentryLevel.FATAL
sut.log(expectedLevel, expectedMessage)
Expand All @@ -79,7 +79,7 @@ class DiagnosticLoggerTest {

@Test
fun `when debug is false and option level is fatal, a call to log and level error is not logged`() {
fixture.options!!.isDebug = false
fixture.options.isDebug = false
val sut = fixture.getSut()
val expectedLevel = SentryLevel.FATAL
sut.log(expectedLevel, expectedMessage)
Expand All @@ -88,7 +88,7 @@ class DiagnosticLoggerTest {

@Test
fun `when debug is true option level is info, a call to log and level debug is not logged`() {
fixture.options!!.setDiagnosticLevel(SentryLevel.FATAL)
fixture.options.setDiagnosticLevel(SentryLevel.FATAL)
val sut = fixture.getSut()
val expectedLevel = SentryLevel.DEBUG
sut.log(expectedLevel, expectedMessage)
Expand All @@ -97,7 +97,7 @@ class DiagnosticLoggerTest {

@Test
fun `when debug is true option level is debug, a call to log with throwable and level info is logged`() {
fixture.options!!.setDiagnosticLevel(SentryLevel.DEBUG)
fixture.options.setDiagnosticLevel(SentryLevel.DEBUG)
val sut = fixture.getSut()
val expectedLevel = SentryLevel.INFO
sut.log(expectedLevel, expectedMessage, expectedThrowable)
Expand All @@ -106,8 +106,8 @@ class DiagnosticLoggerTest {

@Test
fun `when debug is false option level is debug, a call to log with throwable and level info is not logged`() {
fixture.options!!.isDebug = false
fixture.options!!.setDiagnosticLevel(SentryLevel.DEBUG)
fixture.options.isDebug = false
fixture.options.setDiagnosticLevel(SentryLevel.DEBUG)
val sut = fixture.getSut()
val expectedLevel = SentryLevel.INFO
sut.log(expectedLevel, expectedMessage, expectedThrowable)
Expand All @@ -116,7 +116,7 @@ class DiagnosticLoggerTest {

@Test
fun `when debug is true option level is error, a call to log with throwable and level fatal is logged`() {
fixture.options!!.setDiagnosticLevel(SentryLevel.ERROR)
fixture.options.setDiagnosticLevel(SentryLevel.ERROR)
val sut = fixture.getSut()
val expectedLevel = SentryLevel.FATAL
sut.log(expectedLevel, expectedMessage, expectedThrowable)
Expand All @@ -125,26 +125,26 @@ class DiagnosticLoggerTest {

@Test
fun `when debug is true option level is error, a call to log with throwable and level error is logged`() {
fixture.options!!.setDiagnosticLevel(SentryLevel.ERROR)
fixture.options.setDiagnosticLevel(SentryLevel.ERROR)
val sut = fixture.getSut()
val expectedLevel = fixture.options!!.diagnosticLevel
val expectedLevel = fixture.options.diagnosticLevel
sut.log(expectedLevel, expectedMessage, expectedThrowable)
verify(fixture.logger)!!.log(expectedLevel, expectedMessage, expectedThrowable)
}

@Test
fun `when debug is true option level is error, a call to log and level error is logged`() {
fixture.options!!.setDiagnosticLevel(SentryLevel.ERROR)
fixture.options.setDiagnosticLevel(SentryLevel.ERROR)
val sut = fixture.getSut()
val expectedLevel = fixture.options!!.diagnosticLevel
val expectedLevel = fixture.options.diagnosticLevel
sut.log(expectedLevel, expectedMessage)
verify(fixture.logger)!!.log(expectedLevel, expectedMessage)
}

@Test
fun `when debug is false option level is fatal, a call to log with throwable and level error is not logged`() {
fixture.options!!.isDebug = false
fixture.options!!.setDiagnosticLevel(SentryLevel.FATAL)
fixture.options.isDebug = false
fixture.options.setDiagnosticLevel(SentryLevel.FATAL)
val sut = fixture.getSut()
val expectedLevel = SentryLevel.ERROR
sut.log(expectedLevel, expectedMessage, expectedThrowable)
Expand All @@ -153,7 +153,7 @@ class DiagnosticLoggerTest {

@Test
fun `when debug is true option level is info, a call to log with throwable and level debug is not logged`() {
fixture.options!!.setDiagnosticLevel(SentryLevel.INFO)
fixture.options.setDiagnosticLevel(SentryLevel.INFO)
val sut = fixture.getSut()
val expectedLevel = SentryLevel.DEBUG
sut.log(expectedLevel, expectedMessage, expectedThrowable)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,19 +37,19 @@ class SendCachedEventFireAndForgetIntegrationTest {

@Test
fun `path is invalid if it is null`() {
val sut = fixture.getSut()
fixture.getSut()
assertFalse(fixture.callback.hasValidPath(null, fixture.logger))
}

@Test
fun `path is invalid if it is empty`() {
val sut = fixture.getSut()
fixture.getSut()
assertFalse(fixture.callback.hasValidPath("", fixture.logger))
}

@Test
fun `path is valid if not null or empty`() {
val sut = fixture.getSut()
fixture.getSut()
assertFalse(fixture.callback.hasValidPath("cache", fixture.logger))
}

Expand Down
13 changes: 0 additions & 13 deletions sentry-core/src/test/java/io/sentry/core/SentryClientTest.kt
Original file line number Diff line number Diff line change
Expand Up @@ -403,19 +403,6 @@ class SentryClientTest {
assertEquals(transportGate, sentryOptions.transportGate)
}

@Test
fun `when transport gate is null, it should init an always on transport gate`() {
val sentryOptions: SentryOptions = SentryOptions().apply {
dsn = dsnString
}

val connection = mock<AsyncConnection>()
SentryClient(sentryOptions, connection)

assertNotNull(sentryOptions.transportGate)
assertTrue(sentryOptions.transportGate!!.isConnected)
}

@Test
fun `when scope has event processors, they should be applied`() {
val event = SentryEvent()
Expand Down