import java.util.Calendar;
import java.util.GregorianCalendar;
+import org.eclipse.jgit.junit.MockSystemReader;
+import org.junit.After;
+import org.junit.Before;
import org.junit.experimental.theories.DataPoints;
import org.junit.experimental.theories.Theories;
import org.junit.experimental.theories.Theory;
public class GitDateParserBadlyFormattedTest {
private String dateStr;
+ @Before
+ public void setUp() {
+ MockSystemReader mockSystemReader = new MockSystemReader();
+ SystemReader.setInstance(mockSystemReader);
+ }
+
+ @After
+ public void tearDown() {
+ SystemReader.setInstance(null);
+ }
+
public GitDateParserBadlyFormattedTest(String dateStr) {
this.dateStr = dateStr;
}