About this course
This course introduces Java developers to the concepts of test-driven development and automated testing using JUnit, Mockito and Selenium.Why you want to attend
You should attend the Automated Testing for Java Developers course if:- You are a programmer or developer and you need to understand, use and write automated tests.
- You are an analyst or system architect and you want to understand test-driven development.
- You are a project or programme manager, and you want to improve the quality of your team’s code through a test-driven development methodology.
What you need to know first
Before you attend the Automated Testing for Java Developers course:- You must have attended our Java Programming course or already be comfortable with the fundamentals of the Java programming language.
Price and duration
Price: R5,500.00 excluding VAT per delegate. This price includes everything that you need:- All course material, provided in an electronic format.
- An attendance certificate after the course, in PDF format.
How to book
It’s so easy to book for the Automated Testing using Java Developers course. Just email us at info@incusdata.com. You can send us a purchase order, or fill in our course enrolment form. After we have received your booking, we will confirm that you are booked, and we’ll send you an invoice.Detailed course contents
Overview of Unit Testing
- Types of testing: unit, integration, functional, system.
- Why is unit testing needed?
- Properties of good tests.
- Advantages of automating tests.
- Planning and structuring unit tests.
- Improving test quality and effectiveness.
- Continuous testing and integration.
JUnit Features
- JUnit versions – JUnit 4 vs. JUnit 5.
- JUnit framework and test skeletons.
- Test fixtures, cases, suites and runners.
- Exception testing.
- Parameterised tests.
- Rules, theories and categories.
- Other assertion libraries: Hamcrest, AssertJ, Truth.
Developing JUnit Tests
- Writing test methods using assertions and the assertXxx() methods.
- Basic annotations: @Test, @Before, @After, @BeforeClass, @AfterClass, @Ignore.
- Creating and organizing test fixtures with @Before/@After.
- Testing for exceptions.
- Composing test cases into test suites.
- Organising tests and combining test suites.
- Executing tests and showing test results.
Selenium
- Selenium WebDriver as a language-neutral interface for controlling web browsers.
- Writing Selenium scripts for automated web application testing.
- Selenium browser commands: Starting a browser session, navigating to a web page, requesting browser info, setting a waiting strategy, finding a page element, sending an element action, requesting element info, ending a session.
- Selenium 3 vs Selenium 4.
Using Mock Objects
- Why use mocking?
- Dummy vs fake objects vs stubbing vs mocking.
- Mocking to test the functionality of a class in isolation.
- Mock objects as proxies for class implementations.
- Mocking frameworks: Mockito, JMockit, EasyMock.