Unit Testing of Spring MVC Controllers: REST API

preview_player
Показать описание
This screencast describes how we can write comprehensive, readable and fast unit tests for a REST API by using the Spring MVC Test Framework.

If you want to learn how to write unit tests for Spring web applications, take a look at my Test With Spring course:

Adding Validation to a REST API:

Get the example application:

Original blog post:
Рекомендации по теме
Комментарии
Автор

I'm new on Spring, and was looking for a well explained tutorial.
Your videos are all well explained, helped me a lot to learn how to test controllers on Spring, Thank you very much!

marcoprado
Автор

I'm new on Spring, and was looking for a well explained tutorial.
Your videos are all well explained, helped me a lot to learn how to test controllers on Spring, Thank you very much!
Can you add videos on testing sevice and repository layer

sebastianthomas
Автор

hi..

Petri Kainulainen

nice video man!

poojaumesh
Автор

can you please add links for first two videos of this series.

kalyanchakravarthyyellapragada
Автор

Does this test an instance of the REST Controller? Do these tests hit the database and if so should we follow a pattern like create -> verify exists -> delete so that it does not interfere with our application?

daniilzadorozhnyy
Автор

Awesome video. Subscribed your channel.

genuineprofile
Автор

I'm getting a 200 status but getting no JSON response. can anybody help me why I'm getting it. I did the same as whats told in tutorial

trayivankamamidi