Page History
...
Magnolia uses JUnit 4 tests and Mockito (new) for creating unit tests. Before we were using EasyMock for dynamic mocks.
Independently from that make sure your tests match our conventions. Additional information Information on how to best migrate JUnit3-style tests to JUnit4 can be found here.
...
- all new tests requiring dynamic mocks use Mockito
- whenever you touch (fix, adapt, complete) an existing test that's using EasyMock: convert it to Mockito
Setting up for Magnolia testing
There are some handy classes available when creating tests for your Magnolia functionality. To get them working in your Maven project, add the following dependencies to your project descriptor.
...
title | pom.xml |
---|
...
Magnolia Mocking overview
...
Overview
Content Tools