Just an FYI, you may want to check out the JUnit Rule concept for checks like this.