@Test
public void testCheckArgumentShouldThrowIllegalArgumentExceptionIfExpressionIsFalseAndReturnFormattedMessage() {

    // Given:
    expectedException.expect(IllegalArgumentException.class);
    expectedException.expectMessage("error message template");
    // When:
    Preconditions.checkArgument(1 == 2, "error message %s", "template");
    // Then: expect exception
}