JUnit and Mockito Crash Course
4.4 (601 ratings)
Instead of using a simple lifetime average, Udemy calculates a course's star rating by considering a number of different factors such as the number of ratings, the age of ratings, and the likelihood of fraudulent ratings.
3,188 students enrolled
Wishlisted Wishlist

Please confirm that you want to add JUnit and Mockito Crash Course to your Wishlist.

Add to Wishlist

JUnit and Mockito Crash Course

Learn how to use JUnit and Mockito and Unit Test in easy steps.
Bestselling
4.4 (601 ratings)
Instead of using a simple lifetime average, Udemy calculates a course's star rating by considering a number of different factors such as the number of ratings, the age of ratings, and the likelihood of fraudulent ratings.
3,188 students enrolled
Last updated 1/2017
English
English
Current price: $10 Original price: $20 Discount: 50% off
1 day left at this price!
30-Day Money-Back Guarantee
Includes:
  • 3.5 hours on-demand video
  • 1 Article
  • 3 Supplemental Resources
  • Full lifetime access
  • Access on mobile and TV
  • Certificate of Completion
What Will I Learn?
  • Learn what Unit Testing is
  • Understand the importance of Unit Testing
  • Learn the JUnit Framework and API
  • Learn what mocking is and why we should mock
  • Write tests using JUnit and Mockito
  • Learn What Test Coverage is and how to measure it
  • All in simple and easy steps
  • Spring Testing Quick Start
  • PowerMock Quick Start
  • Parameterized JUnit
View Curriculum
Requirements
  • Java Knowledge
  • Eclipse IDE Kepler(or Higher) For Java Developers
Description

Are you a java developer who want to become an expert at Unit Testing ? Then this course is a quick practical guide for you. Learn how to write real unit tests using JUnit and Mockito. This course will simplify things with concepts and step by step implementations .

There are so many java professionals who write great code , but not unit tests. This course aims at filling that gap by covering JUnit and Mockito the two required frameworks to write good unit tests.

Learn and master the most popular unit testing technologies in this comprehensive course.

  • Understand the importance of writing Unit Tests
  • Demystify the topics of Mocking
  • Write Unit tests using JUnit and Mockito
  • Learn what test coverage is and how to measure it
  • Run unit tests as a part of your Maven build
  • All in easy steps

Mastering Unit Testing for Java Professionals:

JUnit is a open source Framework to test and assert code behavior . Mockito mocks out the dependencies and stub the expectations allowing testing a particular layer/unit in isolation.

Any java developer at any level can access the key lessons and concepts in this course and learn to write quality unit tests.

This course is perfect for every java developer who works on building high quality applications .

Contents and Overview:

In over 2 hours of lectures this course covers necessary JUnit API and its usage with Mockito.

This course covers the importance of unit testing , how to effectively use JUnit ,how mocking works and how to use Mockito to write real unit tests.

Up on completion you will be able to test Java and JavaEE applications ,run unit tests as a part of your build and measure code coverage and improve it.

Who is the target audience?
  • Anyone who wants to write quality code
  • Student with java background
  • Java Developers
  • Java EE Developers
Students Who Viewed This Course Also Viewed
Curriculum For This Course
67 Lectures
03:21:28
+
Software Setup
1 Lecture 03:18
+
Introduction
2 Lectures 05:52

Unit Testing Introduction
04:06

Unit Testing Introduction
4 questions
+
JUnit in Action
5 Lectures 21:55

JUnit Introduction
05:05

JUnit Introductioin
5 questions

Hello JUnit
06:48

Hello JUnit
1 question

Testing for Exceptions
05:20

Exceptions
1 question

@Before and @After
04:18

Before and After
1 question
+
Mockito in Action
14 Lectures 43:51

Mocking Introduction
04:02

Mocking Introduction
2 questions

The Order Processor Usecase
01:25

Create the DAO Layer
04:45

Create the BO Layer
07:55

Add the Mockito Dependency
02:33

Stubbing and Setting Expectations
06:03

Stubbing and setting expectations
4 questions

Verify the results
03:17

Verify the results
2 questions

Test a negative scenario
02:50

Mocking Exceptions
02:29

Test Cancel Order
03:19

Cancel Order Negative Scenario
01:13

Cancel Order Exception Scenario
01:52

Cancel Order Exception On Update
01:46
+
Test Coverage
5 Lectures 11:19

Test Coverage
02:40

Test Coverage
2 questions

EclEmma Installation
01:43

Measuring coverage using Emma
03:11

Improving the Coverage
03:26
+
More Mockito
8 Lectures 19:17

Verification Mode
02:15

Verify More
02:53

Create the ScrapBook Project
04:08

Add the Mockito Dependency
01:21

Stub Void Methods Implicitly
04:52

Stub Void Methods Explicitly
00:45

Use doNothing to test Consecutive calls
02:47
+
Best Practices and Patterns
5 Lectures 16:46
The F.I.R.S.T Principle
03:18

Test Doubles Introduction
01:54

Test Doubles In Mockito
03:04

Partial Mocking Using Mockito Spy
06:17

Spy vs Mock
02:13
+
Maven and JUnit Quick Start
3 Lectures 12:51
Maven Overview
04:00

Creating a Maven Project
04:03

Running Tests
04:48
+
Parameterized JUnit
5 Lectures 12:44

Create The Fields and Constructor
02:49

Create The Static Data Set Method
02:53

Create or Update The Test
02:33

The Parameterized Test Flow
01:33

Parameterized JUnits
3 questions
+
PowerMock Jump Start
6 Lectures 17:55

PowerMock Jump Start
2 questions

Usecase
01:10

Create the project
04:11

Download and Add PowerMock Dependencies
02:46

Prepare For Testing
02:18

Mock Static Methods and Test
04:31
2 More Sections
About the Instructor
Bharath Thippireddy
4.5 Average rating
4,282 Reviews
25,595 Students
10 Courses
Java Architect and Instructor at Vivekananda Consulting USA

I have 13 + years of Software design and development Experience. While working for companies like Oracle, HP, TCS, Siemens and NCR I have architected applications using Java, JEE, Java Script and SOA technologies.

I love learning new things both in technology and personal development and I love sharing them - "Sharing is learning!”. I have mentored students in class room trainings as well as in the corporate world both in India as well as in USA.I also share my adventures on my website and YouTube channels.

I have spoken on technical topics at several agile conferences. While in India I also voluntarily teach interview and soft skills at Vivekananda Kendra.

I am a Sun Certified Developer, Web Component Developer, Business Component Developer, Web Services Developer.