Zum Inhalt springen

Christians BLOG

Cut and Paste ersetzt kein Denken.

  • Datenschutzerklärung
  • Impressum

Schlagwort: Spring

5. November 2020 christian

Test private methods

Sometimes a method you want to test is private and cannot be called directly from a junit test. Of course

Weiterlesen
3. April 2020 christian

Simple test with Spring services and mocks

This is a sample how to use mocks in a junit test class:

Weiterlesen
27. Juni 2019 christian

Mocking a Spring service with Mockito for a JUnit test

First define the bean to be mocked in your XML like this Then you can inject it into other beans

Weiterlesen
7. Januar 2019 christian

Define Spring Beans inline JUnit test

Sometimes you like to define some Spring beans in a JUnit test and do not want to create extra files

Weiterlesen

Neueste Beiträge

  • Arduino mit KNX verbinden
  • Ultraschallsensor HC-SR04 am Calliope Mini
  • Wetterstation ELV WS980WiFi
  • Motorsteuerung Calliope Mini für LEGO 9V-Motoren
  • Test private methods

Neueste Kommentare

    Archive

    • Januar 2024
    • Februar 2022
    • Juli 2021
    • November 2020
    • April 2020
    • Juni 2019
    • April 2019
    • Januar 2019
    • Dezember 2018
    • November 2018

    Kategorien

    • Allgemein
    • Java
    • Projekte

    Meta

    • Anmelden
    • Feed der Einträge
    • Kommentar-Feed
    • WordPress.org
    WordPress Theme: Wellington by ThemeZee.