VOOZH about

URL: https://www.javacodegeeks.com/tag/mockito/page/4

⇱ Mockito Archives - Page 4 of 8 - Java Code Geeks


  • Enterprise Java👁 Image
    Ted VinkeJuly 8th, 2020
    0 3,349

    Mockito: Cannot instantiate @InjectMocks field: the type is an abstract class

    Anyone who has used Mockito for mocking and stubbing Java classes, probably is familiar with the InjectMocks-annotation. Use this annotation…

    Read More »
  • Enterprise Java👁 Image
    Ted VinkeJuly 7th, 2020
    0 24,143

    Mockito: Cannot instantiate @InjectMocks field: the type is an interface

    Anyone who has used Mockito for mocking and stubbing Java classes, probably is familiar with the InjectMocks-annotation. Use this annotation…

    Read More »
  • Enterprise Java👁 Image
    StacktraceguruJune 22nd, 2020
    1 12,625

    Mock Void method with Mockito

    Hey guys! After our previous blog on difference between thenReturn and thenAnswer mockito methods, we are back with yet another…

    Read More »
  • Enterprise Java👁 Image
    StacktraceguruMay 15th, 2020
    0 4,166

    Mockito ‘thenReturn’ vs Mockito ‘thenAnswer’

    When it comes to writing test cases for code, Mockito is one of the most common choices of developers. Then…

    Read More »
  • Enterprise Java👁 Image
    MD Sayem AhmedApril 30th, 2020
    0 1,017

    Clean Code from the Trenches – Writing Executable Specifications with JUnit 5, Mockito, and AssertJ

    Executable Specifications are tests that can also serve as design specifications. They enable technical and business teams to get on…

    Read More »
  • Core Java👁 Image
    Ashley FriezeApril 26th, 2020
    0 174

    Mockito Matchers Precedence

    This post is opinion. Let’s look at the verify method in Mockito for testing in Java. Example: verify(myMock).someFunction(123) – expects…

    Read More »
  • Enterprise Java👁 Image
    Sam DaviesAugust 28th, 2019
    3 263

    Seven Testing Sins and How To Avoid Them

    Throughout this article I will be using Java within code snippets, whilst also using JUnit and Mockito. This article aims…

    Read More »
  • Enterprise Java👁 Image
    Marcin ZajaczkowskiSeptember 17th, 2018
    0 187

    Simplify integration testing of legacy application with Spock 1.2

    Learn how leverage Spock 1.2 to slice a Spring context of a legacy application writing integration tests. Have you ever…

    Read More »
  • Core Java👁 Image
    Fahd ShariffSeptember 10th, 2018
    5 7,921

    Java: Mocking a ResultSet using Mockito

    This post shows how you can mock a java.sql.ResultSet using Mockito. It can be used to help unit test code…

    Read More »
  • First
  • ...
  • «
  • 2
  • 3
  • 4
  • 5
  • 6
  • »
  • ...
  • Last
Back to top button
Close