void () { // TestNG order should be (actual, expected) Assert.assertEquals(actual(), "expected"); Assert.<warning descr="Arguments to 'assertEquals()' in wrong order">assertEquals</warning>("hello", actual()); }