Skip to content
Snippets Groups Projects
Commit 424ef188 authored by Motomu Utsumi's avatar Motomu Utsumi Committed by Gerrit Code Review
Browse files

Merge "clearInlineMocks from DevSdkIgnoreRunner after running test" into main

parents 61fba508 05bf4f39
No related branches found
No related tags found
No related merge requests found
......@@ -31,6 +31,7 @@ import org.junit.runner.manipulation.Sorter
import org.junit.runner.notification.Failure
import org.junit.runner.notification.RunNotifier
import org.junit.runners.Parameterized
import org.mockito.Mockito
/**
* A runner that can skip tests based on the development SDK as defined in [DevSdkIgnoreRule].
......@@ -124,6 +125,9 @@ class DevSdkIgnoreRunner(private val klass: Class<*>) : Runner(), Filterable, So
notifier.fireTestFailure(Failure(leakMonitorDesc,
IllegalStateException("Unexpected thread changes: $threadsDiff")))
}
// Clears up internal state of all inline mocks.
// TODO: Call clearInlineMocks() at the end of each test.
Mockito.framework().clearInlineMocks()
notifier.fireTestFinished(leakMonitorDesc)
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment