Chedy2149
Chedy2149

Reputation: 3051

How to enable assertions when running code(tests) with maven?

I wish to run my projects tests using maven with the assertion facility enabled (assert).
Normally I would set an argument when launching the JVM, How Can I do such a thing with Maven?

Upvotes: 3

Views: 1489

Answers (1)

khmarbaise
khmarbaise

Reputation: 97487

The simplest solution is to use the defaults of the maven-surefire-plugin cause it has already activated the assertions

Upvotes: 2

Related Questions