@Mock | @InjectMocks | Difference

  Рет қаралды 17,298

Java Shastra

Java Shastra

Күн бұрын

Пікірлер: 27
@leecha9512
@leecha9512 3 ай бұрын
I subscribed to your channel only watching this video. Excellent explanation!
@Tommy-nn8xf
@Tommy-nn8xf 3 жыл бұрын
Thank you for your concise and understandable explanation! I was so confused after going through many articles, but finally understand it in your video.
@JavaShastra
@JavaShastra 3 жыл бұрын
Thank you 😊,
@shashankshekhar7061
@shashankshekhar7061 4 жыл бұрын
Very lucid explanation , Thanks :)
@ABHINAVKUMAR-vh3ln
@ABHINAVKUMAR-vh3ln 2 жыл бұрын
Thank you. God bless you.
@JavaShastra
@JavaShastra 2 жыл бұрын
Thank you for your feedback 😊.
@manognajoshik8465
@manognajoshik8465 2 жыл бұрын
You have got a new subscriber!!
@JavaShastra
@JavaShastra 2 жыл бұрын
Appreciate 😊, This will motivate me to upload more such content .
@manognajoshik8465
@manognajoshik8465 2 жыл бұрын
@@JavaShastra keep up the good work, I loved the way you illustrated the difference. Underrated channel it is!!
@eddylequartier
@eddylequartier Жыл бұрын
Hello. I have a question. As UserService class is a @Service bean, why you do not use @Resource on UserService class and @MockBean on its child field dao ?
@KermitDominicano
@KermitDominicano 2 жыл бұрын
Thank you!!! Very good, easy to follow explanation
@ganeshk8682
@ganeshk8682 3 жыл бұрын
appreciate ..keep posting good videos
@prasanna6754
@prasanna6754 3 жыл бұрын
Helped it sir.Thank you
@JavaShastra
@JavaShastra 3 жыл бұрын
Thanks
@pandipalanichamy9319
@pandipalanichamy9319 3 жыл бұрын
very nice explanation
@JavaShastra
@JavaShastra 2 жыл бұрын
Thanks and welcome
@aishwaraybhatnagar
@aishwaraybhatnagar 4 жыл бұрын
Nicely explained.
@JavaShastra
@JavaShastra 4 жыл бұрын
Thank you for your encouraging words , it will help me to create such more contents.
@profindia
@profindia 3 жыл бұрын
Nice explanation. Can you explain what is the value of variable 'id', which is used in assert method? If the value of id is from when clause and not from the actual DB call, then what is the purpose of this approach?
@JavaShastra
@JavaShastra 3 жыл бұрын
Yes Mahesh, That is the concept of mocking, Here our core duty is we need to test a particular code in service layer. We are not bothered about DAO layer. So instead hitting in to DB, we will get the mock data, so here variable id is the Mock Data. This the concept of Mocking. For Mocking and unit tests You can watch more videos: kzbin.info/aero/PLBb5HFCJVQtucUCR91j_rqWIr3XpLFXVc
@profindia
@profindia 3 жыл бұрын
Super explanation
@JavaShastra
@JavaShastra 3 жыл бұрын
Thank you 🙂, for your comment , this will keep me uploading more videos.
@letsexplore7806
@letsexplore7806 3 жыл бұрын
Thanks
@JavaShastra
@JavaShastra 3 жыл бұрын
Thank you for your valuable comment, this will help me to upload to such more content.
@rowland138
@rowland138 5 ай бұрын
Rajnikant, ennaraskkalla
@PianoNumberOne
@PianoNumberOne 2 жыл бұрын
Extremely Confusing ...You confused more
@JavaShastra
@JavaShastra 2 жыл бұрын
Which statement u got confused ? Let me know
小丑女COCO的审判。#天使 #小丑 #超人不会飞
00:53
超人不会飞
Рет қаралды 16 МЛН
What is JUnit? | Why Mockito?
14:38
Telusko
Рет қаралды 376 М.
Spy with Mockito -  Spy vs Mock
12:24
in28minutes
Рет қаралды 45 М.
Mocks, Stubs and Spies with Mockito - JUnit Tutorial
14:59
Aneesh Mistry
Рет қаралды 44 М.
Spring Boot - Testing basics
16:05
Defog Tech
Рет қаралды 77 М.
Mockito JUnit Example
18:53
Telusko
Рет қаралды 335 М.
How to use @InjectMocks with Mockito - Tutorial
7:39
Aneesh Mistry
Рет қаралды 9 М.
AI Is Making You An Illiterate Programmer
27:22
ThePrimeTime
Рет қаралды 266 М.