Skip to content

Commit

Permalink
Android team doesn't want to use new mockito for now, so, IdeTooltipM…
Browse files Browse the repository at this point in the history
…anager class cannot be final

Close #1226, Close #1228

GitOrigin-RevId: 5404091a287083aaa4856a7261908876efc3486e
  • Loading branch information
develar authored and intellij-monorepo-bot committed Nov 13, 2019
1 parent 07e34c2 commit d8d2676
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
Expand Up @@ -43,7 +43,8 @@
import java.awt.event.MouseEvent;
import java.lang.reflect.Field;

public final class IdeTooltipManager implements Disposable, AWTEventListener {
// Android team doesn't want to use new mockito for now, so, class cannot be final
public class IdeTooltipManager implements Disposable, AWTEventListener {
public static final ColorKey TOOLTIP_COLOR_KEY = ColorKey.createColorKey("TOOLTIP", null);

private static final Key<IdeTooltip> CUSTOM_TOOLTIP = Key.create("custom.tooltip");
Expand Down
Expand Up @@ -41,7 +41,8 @@
import java.util.List;
import java.util.*;

public final class UndoManagerImpl extends UndoManager implements Disposable {
// Android team doesn't want to use new mockito for now, so, class cannot be final
public class UndoManagerImpl extends UndoManager implements Disposable {
private static final Logger LOG = Logger.getInstance(UndoManagerImpl.class);

@TestOnly
Expand Down

2 comments on commit d8d2676

@dahlstrom-g
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for making this easier on us.

For what it's worth, it's not that we don't want to use a “new mockito”—we use the same version as IntelliJ—but we'd rather not set up extensions for alternative mocking implementations in order to make some classes final when it's simpler to avoid that.

Incidentally test speed is a significant issue for us and the mock-maker-inline extension is much slower; see Mockito issue 1142.

@dahlstrom-g
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See also Mockito issue 1614.

Please sign in to comment.