Upgrading org.mockito:mockito-core 3 to 4
Unknown3.12.4 → 4.11.0
Fetching 16 releases from GitHub…0 / 16
UnknownUpgrade verdict
DepDelta is still reading the notes for this range, so breaking changes can't be ruled out yet.
In plain terms
- DepDelta is still reading the release notes in this range, so it can't rule out breaking changes yet.
- This page updates as the notes come in.
Must act Still reading release notes
DepDelta is still reading the release notes in this range. This updates as they come in.
Moves net.bytebuddy:byte-buddy 1.11.13 → 1.12.19, net.bytebuddy:byte-buddy-agent 1.11.13 → 1.12.19, org.objenesis:objenesis 3.2 → 3.3. Your build may pick other versions.
API changes
Generated by DepDelta from published JVM bytecode. Not mixed with prose notes.
- removed:
class Matchers extends ArgumentMatchers - removed:
ctor Matchers() - removed:
interface MockitoDebugger - removed:
method Answers.get(): Answer - removed:
method BDDMockito.BDDStubber.willNothing(): BDDMockito.BDDStubber - removed:
method BDDMockito.Then.shouldHaveZeroInteractions(): void - removed:
method MockedStatic.verify(VerificationMode, MockedStatic.Verification): void - removed:
method MockitoDebugger.printInvocations(Object[]): String - removed:
static method ArgumentMatchers.anyCollectionOf(Class): Collection - removed:
static method ArgumentMatchers.anyIterableOf(Class): Iterable - removed:
static method ArgumentMatchers.anyListOf(Class): List - removed:
static method ArgumentMatchers.anyMapOf(Class, Class): Map - removed:
static method ArgumentMatchers.anyObject(): Object - removed:
static method ArgumentMatchers.anySetOf(Class): Set - removed:
static method ArgumentMatchers.anyVararg(): Object - removed:
static method Mockito.verifyZeroInteractions(Object[]): void - added:
@interface DoNotMock - added:
enum Mock.Strictness - added:
final class MockMakers - added:
method ArgumentMatcher.type(): Class - added:
method DoNotMock.reason(): String - added:
method InOrder.verify(MockedStatic, MockedStatic.Verification): void - added:
method InOrder.verify(MockedStatic, MockedStatic.Verification, VerificationMode): void - added:
method Mock.mockMaker(): String - added:
method Mock.strictness(): Mock.Strictness - added:
method MockSettings.mockMaker(String): MockSettings - added:
method MockSettings.strictness(Strictness): MockSettings - added:
static field Mock.Strictness.LENIENT: Mock.Strictness - added:
static field Mock.Strictness.STRICT_STUBS: Mock.Strictness - added:
static field Mock.Strictness.TEST_LEVEL_DEFAULT: Mock.Strictness - added:
static field Mock.Strictness.WARN: Mock.Strictness - added:
static field MockMakers.INLINE: String - added:
static field MockMakers.PROXY: String - added:
static field MockMakers.SUBCLASS: String - added:
static method Mock.Strictness.valueOf(String): Mock.Strictness - added:
static method Mock.Strictness.values(): Mock.Strictness[] - added:
static method Mockito.mock(Object[]): Object - added:
static method Mockito.spy(Object[]): Object
- removed:
interface AnnotationEngine extends AnnotationEngine - removed:
method DefaultMockitoConfiguration.getAnnotationEngine(): AnnotationEngine - removed:
method IMockitoConfiguration.getAnnotationEngine(): AnnotationEngine
- added:
class DoNotMockException extends MockitoException - added:
ctor DoNotMockException(String)
- added:
interface StackTraceCleaner.StackFrameMetadata - added:
method StackTraceCleaner.StackFrameMetadata.getClassName(): String - added:
method StackTraceCleaner.StackFrameMetadata.getFileName(): String - added:
method StackTraceCleaner.StackFrameMetadata.getLineNumber(): int - added:
method StackTraceCleaner.StackFrameMetadata.getMethodName(): String - added:
method StackTraceCleaner.isIn(StackTraceCleaner.StackFrameMetadata): boolean
- removed:
class TooLittleActualInvocations extends MockitoAssertionError - removed:
ctor TooLittleActualInvocations(String) - changed:
class TooFewActualInvocations extends TooLittleActualInvocations → class TooFewActualInvocations extends MockitoAssertionError
- removed:
interface InternalMockHandler extends MockHandler - removed:
method MockedStaticImpl.verify(VerificationMode, MockedStatic.Verification): void - removed:
method MockitoCore.isTypeMockable(Class): boolean - added:
method InOrderImpl.verify(MockedStatic, MockedStatic.Verification, VerificationMode): void
- removed:
method GlobalConfiguration.getAnnotationEngine(): AnnotationEngine - changed:
class IndependentAnnotationEngine implements AnnotationEngine, AnnotationEngine → class IndependentAnnotationEngine implements AnnotationEngine - changed:
class InjectingAnnotationEngine implements AnnotationEngine, AnnotationEngine → class InjectingAnnotationEngine implements AnnotationEngine - changed:
class SpyAnnotationEngine implements AnnotationEngine, AnnotationEngine → class SpyAnnotationEngine implements AnnotationEngine - added:
class DefaultDoNotMockEnforcer implements DoNotMockEnforcer - added:
ctor DefaultDoNotMockEnforcer() - added:
method DefaultDoNotMockEnforcer.checkTypeForDoNotMockViolation(Class): String
- added:
class DefaultMockitoPlugins implements MockitoPlugins - added:
ctor DefaultMockitoPlugins() - added:
method DefaultMockitoPlugins.getDefaultPlugin(Class): Object - added:
method DefaultMockitoPlugins.getInlineMockMaker(): MockMaker - added:
static field DefaultMockitoPlugins.MOCK_MAKER_ALIASES: Set - added:
static method DefaultMockitoPlugins.getDefaultPluginClass(String): String - added:
static method Plugins.getDoNotMockEnforcer(): DoNotMockEnforcer
- added:
method MockSettingsImpl.mockMaker(String): MockSettings - added:
method MockSettingsImpl.strictness(Strictness): MockSettings
- added:
static method BytecodeGenerator.isGroovyMethod(boolean): ElementMatcher
- removed:
class InstantiationException extends MockitoException - removed:
class InstantiatorProvider2Adapter implements InstantiatorProvider - removed:
class InstantiatorProviderAdapter implements InstantiatorProvider2 - removed:
ctor InstantiationException(String, Throwable) - removed:
ctor InstantiatorProvider2Adapter(InstantiatorProvider2) - removed:
ctor InstantiatorProviderAdapter(InstantiatorProvider) - removed:
interface Instantiator - removed:
method Instantiator.newInstance(Class): Object - removed:
method InstantiatorProvider2Adapter.getInstantiator(MockCreationSettings): Instantiator - removed:
method InstantiatorProviderAdapter.getInstantiator(MockCreationSettings): Instantiator
- removed:
field CreationSettings.lenient: boolean - added:
field CreationSettings.mockMaker: String - added:
field CreationSettings.strictness: Strictness - added:
method CreationSettings.getMockMaker(): String - added:
method CreationSettings.getStrictness(): Strictness
- removed:
class LocationImpl implements Location, Serializable - removed:
class MockitoDebuggerImpl implements MockitoDebugger - removed:
class WarningsCollector - removed:
ctor LocationImpl() - removed:
ctor LocationImpl(StackTraceFilter) - removed:
ctor LocationImpl(Throwable, boolean) - removed:
ctor MockitoDebuggerImpl() - removed:
ctor WarningsCollector() - removed:
method LocationImpl.getSourceFile(): String - removed:
method LocationImpl.toString(): String - removed:
method MockitoDebuggerImpl.printInvocations(Object[]): String - removed:
method WarningsCollector.getWarnings(): String - added:
final class LocationFactory - added:
static method LocationFactory.create(): Location - added:
static method LocationFactory.create(boolean): Location
- added:
static method Reporter.strictnessDoesNotAcceptNullParameter(): MockitoException
- added:
method DefaultStackTraceCleaner.isIn(StackTraceCleaner.StackFrameMetadata): boolean
- removed:
class UnusedStubsFinder - removed:
ctor UnusedStubsFinder() - removed:
method UnusedStubsFinder.find(List): List
- removed:
class JUnitFailureHacker - removed:
ctor JUnitFailureHacker() - removed:
method JUnitFailureHacker.appendWarnings(Failure, String): void
- changed:
ctor CapturingMatcher() → ctor CapturingMatcher(Class) - added:
ctor NotNull(Class) - added:
ctor Null(Class) - added:
method And.type(): Class - added:
method Any.type(): Class - added:
method CapturingMatcher.type(): Class - added:
method Equals.type(): Class - added:
method InstanceOf.VarArgAware.type(): Class - added:
method InstanceOf.type(): Class - added:
method Not.type(): Class - added:
method NotNull.type(): Class - added:
method Null.type(): Class - added:
method Or.type(): Class - added:
method Same.type(): Class
- removed:
method InvocationContainerImpl.getInvocationForStubbing(): MatchableInvocation - added:
method InvocationContainerImpl.findStubbedAnswer(): Answer
- changed:
method MockCreationValidator.validateType(Class): void → method MockCreationValidator.validateType(Class, String): void - changed:
static method MockUtil.typeMockabilityOf(Class): MockMaker.TypeMockability → static method MockUtil.typeMockabilityOf(Class, String): MockMaker.TypeMockability
- removed:
final class ListUtil - removed:
interface ListUtil.Converter - removed:
interface ListUtil.Filter - removed:
method ListUtil.Converter.convert(Object): Object - removed:
method ListUtil.Filter.isOut(Object): boolean - removed:
static method ListUtil.convert(Collection, ListUtil.Converter): LinkedList - removed:
static method ListUtil.filter(Collection, ListUtil.Filter): LinkedList
- removed:
abstract class Fields - removed:
ctor Fields() - removed:
ctor Fields.InstanceFields(Object, List) - removed:
method Fields.InstanceFields.assignedValues(): List - removed:
method Fields.InstanceFields.filter(ListUtil.Filter): Fields.InstanceFields - removed:
method Fields.InstanceFields.instanceFields(): List - removed:
method Fields.InstanceFields.names(): List - removed:
method Fields.InstanceFields.notNull(): Fields.InstanceFields - removed:
static class Fields.InstanceFields - removed:
static method Fields.allDeclaredFieldsOf(Object): Fields.InstanceFields - removed:
static method Fields.annotatedBy(Class[]): ListUtil.Filter - removed:
static method Fields.declaredFieldsOf(Object): Fields.InstanceFields - removed:
static method Fields.syntheticField(): ListUtil.Filter
- removed:
method VerificationDataImpl.getWanted(): InvocationMatcher - added:
method AtMost.toString(): String - added:
method Only.toString(): String
- removed:
method VerificationData.getWanted(): InvocationMatcher
- removed:
method Invocation.getRawArguments(): Object[] - removed:
method InvocationFactory.createInvocation(Object, MockCreationSettings, Method, Callable, Object[]): Invocation - added:
method InvocationOnMock.getRawArguments(): Object[]
- added:
method MockCreationSettings.getMockMaker(): String - added:
method MockCreationSettings.getStrictness(): Strictness
- removed:
interface InstantiatorProvider - removed:
method InstantiatorProvider.getInstantiator(MockCreationSettings): Instantiator - added:
interface DoNotMockEnforcer - added:
method DoNotMockEnforcer.checkTypeForDoNotMockViolation(Class): String
- removed:
class ConsoleSpammingMockitoJUnitRunner extends Runner implements Filterable - removed:
class MockitoJUnitRunner extends MockitoJUnitRunner - removed:
class VerboseMockitoJUnitRunner extends Runner implements Filterable - removed:
ctor ConsoleSpammingMockitoJUnitRunner(Class) - removed:
ctor MockitoJUnitRunner(Class) - removed:
ctor MockitoJUnitRunner.Silent(Class) - removed:
ctor MockitoJUnitRunner.Strict(Class) - removed:
ctor VerboseMockitoJUnitRunner(Class) - removed:
method ConsoleSpammingMockitoJUnitRunner.filter(Filter): void - removed:
method ConsoleSpammingMockitoJUnitRunner.getDescription(): Description - removed:
method ConsoleSpammingMockitoJUnitRunner.run(RunNotifier): void - removed:
method MockitoJUnitRunner.filter(Filter): void - removed:
method MockitoJUnitRunner.getDescription(): Description - removed:
method MockitoJUnitRunner.run(RunNotifier): void - removed:
method VerboseMockitoJUnitRunner.filter(Filter): void - removed:
method VerboseMockitoJUnitRunner.getDescription(): Description - removed:
method VerboseMockitoJUnitRunner.run(RunNotifier): void - removed:
static class MockitoJUnitRunner.Silent extends MockitoJUnitRunner - removed:
static class MockitoJUnitRunner.Strict extends MockitoJUnitRunner
- added:
method After.toString(): String - added:
method Timeout.toString(): String