Trait

org.mockito.integrations.scalatest

MockitoFixture

Related Doc: package scalatest

Permalink

trait MockitoFixture extends MockitoSessionFixture with MockitoSugar with ArgumentMatchersSugar

It automatically wraps each test in a MockitoScalaSession so the implicit verifications are applied

Just mix-in after your favourite suite, i.e.

class MyTest extends WordSpec with MockitoFixture
Linear Supertypes
ArgumentMatchersSugar, FunctionMatchers, NullMatchers, StringThatMatchers, ThatMatchers, EqMatchers, AnyMatchers, MockitoSugar, Rest, Verifications, DoSomething, MockitoEnhancer, MockCreator, MockitoSessionFixture, TestSuite, Suite, Serializable, Serializable, Assertions, TripleEquals, TripleEqualsSupport, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. MockitoFixture
  2. ArgumentMatchersSugar
  3. FunctionMatchers
  4. NullMatchers
  5. StringThatMatchers
  6. ThatMatchers
  7. EqMatchers
  8. AnyMatchers
  9. MockitoSugar
  10. Rest
  11. Verifications
  12. DoSomething
  13. MockitoEnhancer
  14. MockCreator
  15. MockitoSessionFixture
  16. TestSuite
  17. Suite
  18. Serializable
  19. Serializable
  20. Assertions
  21. TripleEquals
  22. TripleEqualsSupport
  23. AnyRef
  24. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. class AssertionsHelper extends AnyRef

    Permalink
    Definition Classes
    Assertions
  2. class CheckingEqualizer[L] extends AnyRef

    Permalink
    Definition Classes
    TripleEqualsSupport
  3. class Equalizer[L] extends AnyRef

    Permalink
    Definition Classes
    TripleEqualsSupport
  4. trait NoArgTest extends () ⇒ Outcome with TestData

    Permalink
    Attributes
    protected
    Definition Classes
    TestSuite

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. def !==[T](right: Spread[T]): TripleEqualsInvocationOnSpread[T]

    Permalink
    Definition Classes
    TripleEqualsSupport
  3. def !==(right: Null): TripleEqualsInvocation[Null]

    Permalink
    Definition Classes
    TripleEqualsSupport
  4. def !==[T](right: T): TripleEqualsInvocation[T]

    Permalink
    Definition Classes
    TripleEqualsSupport
  5. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  6. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  7. def ===[T](right: Spread[T]): TripleEqualsInvocationOnSpread[T]

    Permalink
    Definition Classes
    TripleEqualsSupport
  8. def ===(right: Null): TripleEqualsInvocation[Null]

    Permalink
    Definition Classes
    TripleEqualsSupport
  9. def ===[T](right: T): TripleEqualsInvocation[T]

    Permalink
    Definition Classes
    TripleEqualsSupport
  10. def any[T]: T

    Permalink

    Delegates to ArgumentMatchers.any(), it's main purpose is to remove the () out of the method call, if you try to do that directly on the test you get this error

    Delegates to ArgumentMatchers.any(), it's main purpose is to remove the () out of the method call, if you try to do that directly on the test you get this error

    Error:(71, 46) polymorphic expression cannot be instantiated to expected type; found : [T]()T required: String when you try to something like ArgumentMatchers.any

    Definition Classes
    AnyMatchers
  11. def anyBoolean: Boolean

    Permalink

    Delegates to ArgumentMatchers.anyBoolean(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Delegates to ArgumentMatchers.anyBoolean(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Definition Classes
    AnyMatchers
  12. def anyByte: Byte

    Permalink

    Delegates to ArgumentMatchers.anyByte(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Delegates to ArgumentMatchers.anyByte(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Definition Classes
    AnyMatchers
  13. def anyChar: Char

    Permalink

    Delegates to ArgumentMatchers.anyChar(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Delegates to ArgumentMatchers.anyChar(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Definition Classes
    AnyMatchers
  14. def anyDouble: Double

    Permalink

    Delegates to ArgumentMatchers.anyDouble(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Delegates to ArgumentMatchers.anyDouble(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Definition Classes
    AnyMatchers
  15. def anyFloat: Float

    Permalink

    Delegates to ArgumentMatchers.anyFloat(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Delegates to ArgumentMatchers.anyFloat(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Definition Classes
    AnyMatchers
  16. def anyInt: Int

    Permalink

    Delegates to ArgumentMatchers.anyInt(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Delegates to ArgumentMatchers.anyInt(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Definition Classes
    AnyMatchers
  17. def anyIterable[T]: Iterable[T]

    Permalink

    Iterable matcher that use Scala Iterable to avoid compile errors like Error:(40, 60) type mismatch; found : Iterable[String] (in java.util) required: Iterable[?] (in scala.collection.immutable)

    Iterable matcher that use Scala Iterable to avoid compile errors like Error:(40, 60) type mismatch; found : Iterable[String] (in java.util) required: Iterable[?] (in scala.collection.immutable)

    when trying to do something like ArgumentMatchers.anyIterable[String]()

    Definition Classes
    AnyMatchers
  18. def anyList[T]: List[T]

    Permalink

    List matcher that use Scala List to avoid compile errors like Error:(40, 60) type mismatch; found : List[String] (in java.util) required: List[?] (in scala.collection.immutable)

    List matcher that use Scala List to avoid compile errors like Error:(40, 60) type mismatch; found : List[String] (in java.util) required: List[?] (in scala.collection.immutable)

    when trying to do something like ArgumentMatchers.anyList[String]()

    Definition Classes
    AnyMatchers
  19. def anyLong: Long

    Permalink

    Delegates to ArgumentMatchers.anyLong(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Delegates to ArgumentMatchers.anyLong(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Definition Classes
    AnyMatchers
  20. def anyMap[K, V]: Map[K, V]

    Permalink

    Map matcher that use Scala Map to avoid compile errors like Error:(40, 60) type mismatch; found : Map[String, String] (in java.util) required: Map[?] (in scala.collection.immutable)

    Map matcher that use Scala Map to avoid compile errors like Error:(40, 60) type mismatch; found : Map[String, String] (in java.util) required: Map[?] (in scala.collection.immutable)

    when trying to do something like ArgumentMatchers.anyMap[String, String]()

    Definition Classes
    AnyMatchers
  21. def anySeq[T]: Seq[T]

    Permalink

    Seq matcher that use Scala Seq to avoid compile errors like Error:(40, 60) type mismatch; found : List[String] (in java.util) required: Seq[?] (in scala.collection.immutable)

    Seq matcher that use Scala Seq to avoid compile errors like Error:(40, 60) type mismatch; found : List[String] (in java.util) required: Seq[?] (in scala.collection.immutable)

    when trying to do something like ArgumentMatchers.anyList[String]()

    Definition Classes
    AnyMatchers
  22. def anySet[T]: Set[T]

    Permalink

    Set matcher that use Scala Set to avoid compile errors like Error:(40, 60) type mismatch; found : Set[String] (in java.util) required: Set[?] (in scala.collection.immutable)

    Set matcher that use Scala Set to avoid compile errors like Error:(40, 60) type mismatch; found : Set[String] (in java.util) required: Set[?] (in scala.collection.immutable)

    when trying to do something like ArgumentMatchers.anySet[String]()

    Definition Classes
    AnyMatchers
  23. def anyShort: Short

    Permalink

    Delegates to ArgumentMatchers.anyShort(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Delegates to ArgumentMatchers.anyShort(), it's only here so we expose all the ArgumentMatchers on a single place as any[T] would do the job just fine

    Definition Classes
    AnyMatchers
  24. def anyVal[T](implicit valueClassMatchers: ValueClassMatchers[T]): T

    Permalink

    Wraps the standard 'any' matcher on the value class provided, this one requires the type to be explicit

    Wraps the standard 'any' matcher on the value class provided, this one requires the type to be explicit

    Definition Classes
    AnyMatchers
  25. def argThat[T](matcher: ArgumentMatcher[T]): T

    Permalink

    Delegates to ArgumentMatchers.argThat(matcher), it's only here so we expose all the ArgumentMatchers on a single place

    Delegates to ArgumentMatchers.argThat(matcher), it's only here so we expose all the ArgumentMatchers on a single place

    Definition Classes
    ThatMatchers
  26. def argumentCaptor[T](implicit arg0: ClassTag[T]): ArgumentCaptor[T]

    Permalink

    Delegates to ArgumentCaptor.forClass(type: Class[T]) It provides a nicer API as you can, for instance, do argumentCaptor[SomeClass] instead of ArgumentCaptor.forClass(classOf[SomeClass])

    Delegates to ArgumentCaptor.forClass(type: Class[T]) It provides a nicer API as you can, for instance, do argumentCaptor[SomeClass] instead of ArgumentCaptor.forClass(classOf[SomeClass])

    Definition Classes
    Rest
  27. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  28. macro def assert(condition: Boolean, clue: Any)(implicit prettifier: Prettifier, pos: Position): Assertion

    Permalink
    Definition Classes
    Assertions
  29. macro def assert(condition: Boolean)(implicit prettifier: Prettifier, pos: Position): Assertion

    Permalink
    Definition Classes
    Assertions
  30. macro def assertCompiles(code: String)(implicit pos: Position): Assertion

    Permalink
    Definition Classes
    Assertions
  31. macro def assertDoesNotCompile(code: String)(implicit pos: Position): Assertion

    Permalink
    Definition Classes
    Assertions
  32. def assertResult(expected: Any)(actual: Any)(implicit prettifier: Prettifier, pos: Position): Assertion

    Permalink
    Definition Classes
    Assertions
  33. def assertResult(expected: Any, clue: Any)(actual: Any)(implicit prettifier: Prettifier, pos: Position): Assertion

    Permalink
    Definition Classes
    Assertions
  34. def assertThrows[T <: AnyRef](f: ⇒ Any)(implicit classTag: ClassTag[T], pos: Position): Assertion

    Permalink
    Definition Classes
    Assertions
  35. macro def assertTypeError(code: String)(implicit pos: Position): Assertion

    Permalink
    Definition Classes
    Assertions
  36. val assertionsHelper: AssertionsHelper

    Permalink
    Definition Classes
    Assertions
  37. macro def assume(condition: Boolean, clue: Any)(implicit prettifier: Prettifier, pos: Position): Assertion

    Permalink
    Definition Classes
    Assertions
  38. macro def assume(condition: Boolean)(implicit prettifier: Prettifier, pos: Position): Assertion

    Permalink
    Definition Classes
    Assertions
  39. def atLeast(minNumberOfInvocations: Int): VerificationMode

    Permalink

    Delegates to Mockito.atLeast(), it's only here to expose the full Mockito API

    Delegates to Mockito.atLeast(), it's only here to expose the full Mockito API

    Definition Classes
    Verifications
  40. def atLeastOnce: VerificationMode

    Permalink

    Delegates to Mockito.atLeastOnce(), it removes the parenthesis to have a cleaner API

    Delegates to Mockito.atLeastOnce(), it removes the parenthesis to have a cleaner API

    Definition Classes
    Verifications
  41. def atMost(maxNumberOfInvocations: Int): VerificationMode

    Permalink

    Delegates to Mockito.atMost(), it's only here to expose the full Mockito API

    Delegates to Mockito.atMost(), it's only here to expose the full Mockito API

    Definition Classes
    Verifications
  42. def booleanThat(matcher: ArgumentMatcher[Boolean]): Boolean

    Permalink

    Delegates the call to argThat but using the Scala "primitive", this provides avoids an unnecessary implicit conversion that would be necessary if we used the Java version

    Delegates the call to argThat but using the Scala "primitive", this provides avoids an unnecessary implicit conversion that would be necessary if we used the Java version

    Definition Classes
    ThatMatchers
  43. def byteThat(matcher: ArgumentMatcher[Byte]): Byte

    Permalink

    Delegates the call to argThat but using the Scala "primitives", this provides avoids an unnecessary implicit conversion that would be necessary if we used the Java version

    Delegates the call to argThat but using the Scala "primitives", this provides avoids an unnecessary implicit conversion that would be necessary if we used the Java version

    Definition Classes
    ThatMatchers
  44. def calls(wantedNumberOfInvocations: Int): VerificationMode

    Permalink

    Delegates to Mockito.calls(), it's only here to expose the full Mockito API

    Delegates to Mockito.calls(), it's only here to expose the full Mockito API

    Definition Classes
    Verifications
  45. def cancel(cause: Throwable)(implicit pos: Position): Nothing

    Permalink
    Definition Classes
    Assertions
  46. def cancel(message: String, cause: Throwable)(implicit pos: Position): Nothing

    Permalink
    Definition Classes
    Assertions
  47. def cancel(message: String)(implicit pos: Position): Nothing

    Permalink
    Definition Classes
    Assertions
  48. def cancel()(implicit pos: Position): Nothing

    Permalink
    Definition Classes
    Assertions
  49. def charThat(matcher: ArgumentMatcher[Char]): Char

    Permalink

    Delegates the call to argThat but using the Scala "primitive", this provides avoids an unnecessary implicit conversion that would be necessary if we used the Java version

    Delegates the call to argThat but using the Scala "primitive", this provides avoids an unnecessary implicit conversion that would be necessary if we used the Java version

    Definition Classes
    ThatMatchers
  50. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  51. def contains(substring: String): String

    Permalink

    Delegates to ArgumentMatchers.contains(), it's only here so we expose all the ArgumentMatchers on a single place

    Delegates to ArgumentMatchers.contains(), it's only here so we expose all the ArgumentMatchers on a single place

    Definition Classes
    StringThatMatchers
  52. def conversionCheckedConstraint[A, B](implicit equivalenceOfA: Equivalence[A], cnv: (B) ⇒ A): CanEqual[A, B]

    Permalink
    Definition Classes
    TripleEquals → TripleEqualsSupport
  53. def convertEquivalenceToAToBConstraint[A, B](equivalenceOfB: Equivalence[B])(implicit ev: <:<[A, B]): CanEqual[A, B]

    Permalink
    Definition Classes
    TripleEquals → TripleEqualsSupport
  54. def convertEquivalenceToAToBConversionConstraint[A, B](equivalenceOfB: Equivalence[B])(implicit ev: (A) ⇒ B): CanEqual[A, B]

    Permalink
    Definition Classes
    TripleEquals → TripleEqualsSupport
  55. def convertEquivalenceToBToAConstraint[A, B](equivalenceOfA: Equivalence[A])(implicit ev: <:<[B, A]): CanEqual[A, B]

    Permalink
    Definition Classes
    TripleEquals → TripleEqualsSupport
  56. def convertEquivalenceToBToAConversionConstraint[A, B](equivalenceOfA: Equivalence[A])(implicit ev: (B) ⇒ A): CanEqual[A, B]

    Permalink
    Definition Classes
    TripleEquals → TripleEqualsSupport
  57. def convertToCheckingEqualizer[T](left: T): CheckingEqualizer[T]

    Permalink
    Definition Classes
    TripleEquals → TripleEqualsSupport
  58. implicit def convertToEqualizer[T](left: T): Equalizer[T]

    Permalink
    Definition Classes
    TripleEquals → TripleEqualsSupport
  59. def defaultEquality[A]: Equality[A]

    Permalink
    Definition Classes
    TripleEqualsSupport
  60. def doAnswer[T](f: (InvocationOnMock) ⇒ T): Stubber

    Permalink

    Delegates to Mockito.doAnswer(), it's only here to expose the full Mockito API

    Delegates to Mockito.doAnswer(), it's only here to expose the full Mockito API

    Definition Classes
    DoSomething
  61. def doCallRealMethod: Stubber

    Permalink

    Delegates to Mockito.doCallRealMethod(), it removes the parenthesis to have a cleaner API

    Delegates to Mockito.doCallRealMethod(), it removes the parenthesis to have a cleaner API

    Definition Classes
    DoSomething
  62. def doNothing: Stubber

    Permalink

    Delegates to Mockito.doNothing(), it removes the parenthesis to have a cleaner API

    Delegates to Mockito.doNothing(), it removes the parenthesis to have a cleaner API

    Definition Classes
    DoSomething
  63. def doReturn[T](toBeReturned: T, toBeReturnedNext: T*): Stubber

    Permalink

    Delegates the call to Mockito.doReturn(toBeReturned, toBeReturnedNext) but fixes the following compiler issue that happens because the overloaded vararg on the Java side

    Delegates the call to Mockito.doReturn(toBeReturned, toBeReturnedNext) but fixes the following compiler issue that happens because the overloaded vararg on the Java side

    Error:(33, 25) ambiguous reference to overloaded definition,
    both method doReturn in class Mockito of type (x$1: Any, x$2: Object*)org.mockito.stubbing.Stubber
    and  method doReturn in class Mockito of type (x$1: Any)org.mockito.stubbing.Stubber
    match argument types (`Type`)
    Definition Classes
    DoSomething
  64. def doThrow[T <: Throwable](implicit arg0: ClassTag[T]): Stubber

    Permalink

    Delegates to Mockito.doThrow(type: Class[T]) It provides a nicer API as you can, for instance, do doThrow[Throwable] instead of doThrow(classOf[Throwable])

    Delegates to Mockito.doThrow(type: Class[T]) It provides a nicer API as you can, for instance, do doThrow[Throwable] instead of doThrow(classOf[Throwable])

    Definition Classes
    DoSomething
  65. def doThrow(toBeThrown: Throwable*): Stubber

    Permalink

    Delegates to Mockito.doThrow, it's only here so we expose all the Mockito API on a single place

    Delegates to Mockito.doThrow, it's only here so we expose all the Mockito API on a single place

    Definition Classes
    DoSomething
  66. def doubleThat(matcher: ArgumentMatcher[Double]): Double

    Permalink

    Delegates the call to argThat but using the Scala "primitive", this provides avoids an unnecessary implicit conversion that would be necessary if we used the Java version

    Delegates the call to argThat but using the Scala "primitive", this provides avoids an unnecessary implicit conversion that would be necessary if we used the Java version

    Definition Classes
    ThatMatchers
  67. def endsWith(suffix: String): String

    Permalink

    Delegates to ArgumentMatchers.endsWith(), it's only here so we expose all the ArgumentMatchers on a single place

    Delegates to ArgumentMatchers.endsWith(), it's only here so we expose all the ArgumentMatchers on a single place

    Definition Classes
    StringThatMatchers
  68. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  69. def eqTo[T](value: T): T

    Permalink

    Delegates to ArgumentMatchers.eq(), it renames the method to eqTo to avoid clashes with the Scala eq method used for reference equality

    Delegates to ArgumentMatchers.eq(), it renames the method to eqTo to avoid clashes with the Scala eq method used for reference equality

    Definition Classes
    EqMatchers
  70. def eqToVal[T](value: Any)(implicit valueClassMatchers: ValueClassMatchers[T]): T

    Permalink

    Wraps the standard 'ArgumentMatchers.eq()' matcher on the value class provided, this one requires the type to be explicit

    Wraps the standard 'ArgumentMatchers.eq()' matcher on the value class provided, this one requires the type to be explicit

    Definition Classes
    EqMatchers
  71. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  72. final def execute(testName: String, configMap: ConfigMap, color: Boolean, durations: Boolean, shortstacks: Boolean, fullstacks: Boolean, stats: Boolean): Unit

    Permalink
    Definition Classes
    Suite
  73. def expectedTestCount(filter: Filter): Int

    Permalink
    Definition Classes
    Suite
  74. def fail(cause: Throwable)(implicit pos: Position): Nothing

    Permalink
    Definition Classes
    Assertions
  75. def fail(message: String, cause: Throwable)(implicit pos: Position): Nothing

    Permalink
    Definition Classes
    Assertions
  76. def fail(message: String)(implicit pos: Position): Nothing

    Permalink
    Definition Classes
    Assertions
  77. def fail()(implicit pos: Position): Nothing

    Permalink
    Definition Classes
    Assertions
  78. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  79. def floatThat(matcher: ArgumentMatcher[Float]): Float

    Permalink

    Delegates the call to argThat but using the Scala "primitive", this provides avoids an unnecessary implicit conversion that would be necessary if we used the Java version

    Delegates the call to argThat but using the Scala "primitive", this provides avoids an unnecessary implicit conversion that would be necessary if we used the Java version

    Definition Classes
    ThatMatchers
  80. def function0[T](value: T): () ⇒ T

    Permalink
    Definition Classes
    FunctionMatchers
  81. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  82. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  83. def ignoreStubs(mocks: AnyRef*): Array[AnyRef]

    Permalink

    Delegates to Mockito.ignoreStubs(), it's only here to expose the full Mockito API

    Delegates to Mockito.ignoreStubs(), it's only here to expose the full Mockito API

    Definition Classes
    Rest
  84. def inOrder(mocks: AnyRef*): InOrder

    Permalink

    Delegates to Mockito.inOrder(), it's only here to expose the full Mockito API

    Delegates to Mockito.inOrder(), it's only here to expose the full Mockito API

    Definition Classes
    Rest
  85. def intThat(matcher: ArgumentMatcher[Int]): Int

    Permalink

    Delegates the call to argThat but using the Scala "primitive", this provides avoids an unnecessary implicit conversion that would be necessary if we used the Java version

    Delegates the call to argThat but using the Scala "primitive", this provides avoids an unnecessary implicit conversion that would be necessary if we used the Java version

    Definition Classes
    ThatMatchers
  86. def intercept[T <: AnyRef](f: ⇒ Any)(implicit classTag: ClassTag[T], pos: Position): T

    Permalink
    Definition Classes
    Assertions
  87. def isA[T](implicit classTag: ClassTag[T]): T

    Permalink

    Delegates to ArgumentMatchers.isA(type: Class[T]) It provides a nicer API as you can, for instance, do isA[String] instead of isA(classOf[String])

    Delegates to ArgumentMatchers.isA(type: Class[T]) It provides a nicer API as you can, for instance, do isA[String] instead of isA(classOf[String])

    Definition Classes
    EqMatchers
  88. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  89. def longThat(matcher: ArgumentMatcher[Long]): Long

    Permalink

    Delegates the call to argThat but using the Scala "primitive", this provides avoids an unnecessary conversion that would be necessary used the Java version

    Delegates the call to argThat but using the Scala "primitive", this provides avoids an unnecessary conversion that would be necessary used the Java version

    Definition Classes
    ThatMatchers
  90. def lowPriorityConversionCheckedConstraint[A, B](implicit equivalenceOfB: Equivalence[B], cnv: (A) ⇒ B): CanEqual[A, B]

    Permalink
    Definition Classes
    TripleEquals → TripleEqualsSupport
  91. def lowPriorityTypeCheckedConstraint[A, B](implicit equivalenceOfB: Equivalence[B], ev: <:<[A, B]): CanEqual[A, B]

    Permalink
    Definition Classes
    TripleEquals → TripleEqualsSupport
  92. def matches(regex: String): String

    Permalink

    Delegates to ArgumentMatchers.matches(), it's only here so we expose all the ArgumentMatchers on a single place

    Delegates to ArgumentMatchers.matches(), it's only here so we expose all the ArgumentMatchers on a single place

    Definition Classes
    StringThatMatchers
  93. def mock[T <: AnyRef](name: String)(implicit arg0: ClassTag[T], arg1: scala.reflect.api.JavaUniverse.TypeTag[T], defaultAnswer: DefaultAnswer): T

    Permalink

    Delegates to Mockito.mock(type: Class[T], name: String) It provides a nicer API as you can, for instance, do mock[MyClass](name) instead of mock(classOf[MyClass], name)

    Delegates to Mockito.mock(type: Class[T], name: String) It provides a nicer API as you can, for instance, do mock[MyClass](name) instead of mock(classOf[MyClass], name)

    It also pre-stub the mock so the compiler-generated methods that provide the values for the default arguments are called, ie: given def iHaveSomeDefaultArguments(noDefault: String, default: String = "default value")

    without this fix, if you call it as iHaveSomeDefaultArguments("I'm not gonna pass the second argument") then you could have not verified it like verify(aMock).iHaveSomeDefaultArguments("I'm not gonna pass the second argument", "default value") as the value for the second parameter would have been null...

    Definition Classes
    MockitoEnhancer → MockCreator
  94. def mock[T <: AnyRef](mockSettings: MockSettings)(implicit arg0: ClassTag[T], arg1: scala.reflect.api.JavaUniverse.TypeTag[T]): T

    Permalink

    Delegates to Mockito.mock(type: Class[T], mockSettings: MockSettings) It provides a nicer API as you can, for instance, do mock[MyClass](mockSettings) instead of mock(classOf[MyClass], mockSettings)

    Delegates to Mockito.mock(type: Class[T], mockSettings: MockSettings) It provides a nicer API as you can, for instance, do mock[MyClass](mockSettings) instead of mock(classOf[MyClass], mockSettings)

    It also pre-stub the mock so the compiler-generated methods that provide the values for the default arguments are called, ie: given def iHaveSomeDefaultArguments(noDefault: String, default: String = "default value")

    without this fix, if you call it as iHaveSomeDefaultArguments("I'm not gonna pass the second argument") then you could have not verified it like verify(aMock).iHaveSomeDefaultArguments("I'm not gonna pass the second argument", "default value") as the value for the second parameter would have been null...

    Definition Classes
    MockitoEnhancer → MockCreator
  95. def mock[T <: AnyRef](defaultAnswer: DefaultAnswer)(implicit arg0: ClassTag[T], arg1: scala.reflect.api.JavaUniverse.TypeTag[T]): T

    Permalink

    Delegates to Mockito.mock(type: Class[T], defaultAnswer: Answer[_]) It provides a nicer API as you can, for instance, do mock[MyClass](defaultAnswer) instead of mock(classOf[MyClass], defaultAnswer)

    Delegates to Mockito.mock(type: Class[T], defaultAnswer: Answer[_]) It provides a nicer API as you can, for instance, do mock[MyClass](defaultAnswer) instead of mock(classOf[MyClass], defaultAnswer)

    It also pre-stub the mock so the compiler-generated methods that provide the values for the default arguments are called, ie: given def iHaveSomeDefaultArguments(noDefault: String, default: String = "default value")

    without this fix, if you call it as iHaveSomeDefaultArguments("I'm not gonna pass the second argument") then you could have not verified it like verify(aMock).iHaveSomeDefaultArguments("I'm not gonna pass the second argument", "default value") as the value for the second parameter would have been null...

    Definition Classes
    MockitoEnhancer → MockCreator
  96. def mock[T <: AnyRef](implicit arg0: ClassTag[T], arg1: scala.reflect.api.JavaUniverse.TypeTag[T], defaultAnswer: DefaultAnswer): T

    Permalink

    Delegates to Mockito.mock(type: Class[T]) It provides a nicer API as you can, for instance, do mock[MyClass] instead of mock(classOf[MyClass])

    Delegates to Mockito.mock(type: Class[T]) It provides a nicer API as you can, for instance, do mock[MyClass] instead of mock(classOf[MyClass])

    It also pre-stub the mock so the compiler-generated methods that provide the values for the default arguments are called, ie: given def iHaveSomeDefaultArguments(noDefault: String, default: String = "default value")

    without this fix, if you call it as iHaveSomeDefaultArguments("I'm not gonna pass the second argument") then you could have not verified it like verify(aMock).iHaveSomeDefaultArguments("I'm not gonna pass the second argument", "default value") as the value for the second parameter would have been null...

    Definition Classes
    MockitoEnhancer → MockCreator
  97. def mock[T <: AnyRef](defaultAnswer: Answer[_])(implicit arg0: ClassTag[T], arg1: scala.reflect.api.JavaUniverse.TypeTag[T]): T

    Permalink
    Definition Classes
    MockCreator
  98. def mockingDetails(toInspect: AnyRef): MockingDetails

    Permalink

    Delegates to Mockito.mockingDetails(), it's only here to expose the full Mockito API

    Delegates to Mockito.mockingDetails(), it's only here to expose the full Mockito API

    Definition Classes
    MockitoEnhancer
  99. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  100. def nestedSuites: IndexedSeq[Suite]

    Permalink
    Definition Classes
    Suite
  101. def never: VerificationMode

    Permalink

    Delegates to Mockito.never(), it removes the parenthesis to have a cleaner API

    Delegates to Mockito.never(), it removes the parenthesis to have a cleaner API

    Definition Classes
    Verifications
  102. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  103. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  104. def only: VerificationMode

    Permalink

    Delegates to Mockito.only(), it removes the parenthesis to have a cleaner API

    Delegates to Mockito.only(), it removes the parenthesis to have a cleaner API

    Definition Classes
    Verifications
  105. def pending: Assertion with PendingStatement

    Permalink
    Definition Classes
    Assertions
  106. def pendingUntilFixed(f: ⇒ Unit)(implicit pos: Position): Assertion with PendingStatement

    Permalink
    Definition Classes
    Assertions
  107. def refEq[T](value: T, excludeFields: String*): T

    Permalink

    Delegates to ArgumentMatchers.refEq(), it's only here so we expose all the ArgumentMatchers on a single place

    Delegates to ArgumentMatchers.refEq(), it's only here so we expose all the ArgumentMatchers on a single place

    Definition Classes
    EqMatchers
  108. def rerunner: Option[String]

    Permalink
    Definition Classes
    Suite
  109. def reset(mocks: AnyRef*): Unit

    Permalink

    Delegates to Mockito.reset(T... mocks), but restores the default stubs that deal with default argument values

    Delegates to Mockito.reset(T... mocks), but restores the default stubs that deal with default argument values

    Definition Classes
    MockitoEnhancer
  110. def run(testName: Option[String], args: Args): Status

    Permalink
    Definition Classes
    Suite
  111. def runNestedSuites(args: Args): Status

    Permalink
    Attributes
    protected
    Definition Classes
    Suite
  112. def runTest(testName: String, args: Args): Status

    Permalink
    Attributes
    protected
    Definition Classes
    TestSuite → Suite
  113. def runTests(testName: Option[String], args: Args): Status

    Permalink
    Attributes
    protected
    Definition Classes
    Suite
  114. def same[T](value: T): T

    Permalink

    Delegates to ArgumentMatchers.same(), it's only here so we expose all the ArgumentMatchers on a single place

    Delegates to ArgumentMatchers.same(), it's only here so we expose all the ArgumentMatchers on a single place

    Definition Classes
    EqMatchers
  115. def shortThat(matcher: ArgumentMatcher[Short]): Short

    Permalink

    Delegates the call to argThat but using the Scala "primitive", this provides avoids an unnecessary implicit conversion that would be necessary if we used the Java version

    Delegates the call to argThat but using the Scala "primitive", this provides avoids an unnecessary implicit conversion that would be necessary if we used the Java version

    Definition Classes
    ThatMatchers
  116. def spy[T](realObj: T): T

    Permalink

    Delegates to Mockito.spy(), it's only here to expose the full Mockito API

    Delegates to Mockito.spy(), it's only here to expose the full Mockito API

    Definition Classes
    Rest → MockCreator
  117. def spyLambda[T <: AnyRef](realObj: T)(implicit arg0: ClassTag[T]): T

    Permalink

    Creates a "spy" in a way that supports lambdas and anonymous classes as they don't work with the standard spy as they are created as final classes by the compiler

    Creates a "spy" in a way that supports lambdas and anonymous classes as they don't work with the standard spy as they are created as final classes by the compiler

    Definition Classes
    Rest → MockCreator
  118. def startsWith(prefix: String): String

    Permalink

    Delegates to ArgumentMatchers.startsWith(), it's only here so we expose all the ArgumentMatchers on a single place

    Delegates to ArgumentMatchers.startsWith(), it's only here so we expose all the ArgumentMatchers on a single place

    Definition Classes
    StringThatMatchers
  119. val styleName: String

    Permalink
    Definition Classes
    Suite
  120. final val succeed: Assertion

    Permalink
    Definition Classes
    Assertions
  121. def suiteId: String

    Permalink
    Definition Classes
    Suite
  122. def suiteName: String

    Permalink
    Definition Classes
    Suite
  123. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  124. def tags: Map[String, Set[String]]

    Permalink
    Definition Classes
    Suite
  125. def testDataFor(testName: String, theConfigMap: ConfigMap): TestData

    Permalink
    Definition Classes
    Suite
  126. def testNames: Set[String]

    Permalink
    Definition Classes
    Suite
  127. def timeout(millis: Int): VerificationWithTimeout

    Permalink

    Delegates to Mockito.timeout(), it's only here to expose the full Mockito API

    Delegates to Mockito.timeout(), it's only here to expose the full Mockito API

    Definition Classes
    Verifications
  128. def times(wantedNumberOfInvocations: Int): VerificationMode

    Permalink

    Delegates to Mockito.times(), it's only here to expose the full Mockito API

    Delegates to Mockito.times(), it's only here to expose the full Mockito API

    Definition Classes
    Verifications
  129. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  130. def typeCheckedConstraint[A, B](implicit equivalenceOfA: Equivalence[A], ev: <:<[B, A]): CanEqual[A, B]

    Permalink
    Definition Classes
    TripleEquals → TripleEqualsSupport
  131. implicit def unconstrainedEquality[A, B](implicit equalityOfA: Equality[A]): CanEqual[A, B]

    Permalink
    Definition Classes
    TripleEquals → TripleEqualsSupport
  132. def validateMockitoUsage(): Unit

    Permalink

    Delegates to Mockito.validateMockitoUsage(), it's only here to expose the full Mockito API

    Delegates to Mockito.validateMockitoUsage(), it's only here to expose the full Mockito API

    Definition Classes
    Rest
  133. def verify[T](mock: T, mode: VerificationMode): T

    Permalink

    Delegates to Mockito.verify(), it's only here to expose the full Mockito API

    Delegates to Mockito.verify(), it's only here to expose the full Mockito API

    Definition Classes
    Rest
  134. def verify[T](mock: T): T

    Permalink

    Delegates to Mockito.verify(), it's only here to expose the full Mockito API

    Delegates to Mockito.verify(), it's only here to expose the full Mockito API

    Definition Classes
    Rest
  135. def verifyNoMoreInteractions(mocks: AnyRef*): Unit

    Permalink

    Delegates to Mockito.verifyNoMoreInteractions(Object... mocks), but ignores the default stubs that deal with default argument values

    Delegates to Mockito.verifyNoMoreInteractions(Object... mocks), but ignores the default stubs that deal with default argument values

    Definition Classes
    MockitoEnhancer
  136. def verifyZeroInteractions(mocks: AnyRef*): Unit

    Permalink

    Delegates to Mockito.verifyZeroInteractions(), it's only here to expose the full Mockito API

    Delegates to Mockito.verifyZeroInteractions(), it's only here to expose the full Mockito API

    Definition Classes
    Rest
  137. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  138. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  139. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  140. def when[T](methodCall: T): OngoingStubbing[T]

    Permalink

    Delegates to Mockito.when(), it's only here to expose the full Mockito API

    Delegates to Mockito.when(), it's only here to expose the full Mockito API

    Definition Classes
    Rest
  141. def withClue[T](clue: Any)(fun: ⇒ T): T

    Permalink
    Definition Classes
    Assertions
  142. def withFixture(test: NoArgTest): Outcome

    Permalink
    Definition Classes
    MockitoSessionFixture → TestSuite
  143. def withSettings(implicit defaultAnswer: DefaultAnswer): MockSettings

    Permalink

    Delegates to Mockito.withSettings(), it's only here to expose the full Mockito API

    Delegates to Mockito.withSettings(), it's only here to expose the full Mockito API

    Definition Classes
    MockCreator

Deprecated Value Members

  1. final def execute: Unit

    Permalink
    Definition Classes
    Suite
    Annotations
    @deprecated
    Deprecated

    The parameterless execute method has been deprecated and will be removed in a future version of ScalaTest. Please invoke execute with empty parens instead: execute().

  2. def isNotNull[T]: T

    Permalink

    Delegates to ArgumentMatchers.isNotNull(), it's only here so we expose all the ArgumentMatchers on a single place, but marked as @deprecated as you shouldn't be testing for nulls on Scala

    Delegates to ArgumentMatchers.isNotNull(), it's only here so we expose all the ArgumentMatchers on a single place, but marked as @deprecated as you shouldn't be testing for nulls on Scala

    Definition Classes
    NullMatchers
    Annotations
    @deprecated
    Deprecated
  3. def isNull[T]: T

    Permalink

    Delegates to ArgumentMatchers.isNull(), it's only here so we expose all the ArgumentMatchers on a single place, but marked as @deprecated as you shouldn't be testing for nulls on Scala

    Delegates to ArgumentMatchers.isNull(), it's only here so we expose all the ArgumentMatchers on a single place, but marked as @deprecated as you shouldn't be testing for nulls on Scala

    Definition Classes
    NullMatchers
    Annotations
    @deprecated
    Deprecated
  4. def trap[T](f: ⇒ T): Throwable

    Permalink
    Definition Classes
    Assertions
    Annotations
    @deprecated
    Deprecated

    The trap method is no longer needed for demos in the REPL, which now abreviates stack traces, and will be removed in a future version of ScalaTest

Inherited from ArgumentMatchersSugar

Inherited from FunctionMatchers

Inherited from NullMatchers

Inherited from StringThatMatchers

Inherited from ThatMatchers

Inherited from EqMatchers

Inherited from AnyMatchers

Inherited from MockitoSugar

Inherited from Rest

Inherited from Verifications

Inherited from DoSomething

Inherited from MockitoEnhancer

Inherited from MockCreator

Inherited from MockitoSessionFixture

Inherited from TestSuite

Inherited from Suite

Inherited from Serializable

Inherited from Serializable

Inherited from Assertions

Inherited from TripleEquals

Inherited from TripleEqualsSupport

Inherited from AnyRef

Inherited from Any

Ungrouped