package de.jeyp91.apifootball; import org.junit.Test; public class APIFootballUpdaterTest { @Test public void checkErrorsTest() { String exceededLimitDayError = "{\"api\":{\"results\":0,\"error\":\"You have reached the request limit for the day\"}}"; APIFootballUpdater updater = new APIFootballUpdater(); try { updater.checkErrors("https://test.url/api", exceededLimitDayError); } catch (Exception e) { System.out.println(e.getMessage()); assert e.getMessage().equals("https://test.url/api returned error: 'You have reached the request limit for the day'"); } } @Test public void updateFixturesTest() { APIFootballUpdater updater = new APIFootballUpdater(); // updater.updateFixtures(1240); } @Test public void updateAllFixturesTest() { APIFootballUpdater updater = new APIFootballUpdater(); // updater.updateAllFixtures(); } @Test public void updateRoundsTest() { APIFootballUpdater updater = new APIFootballUpdater(); // updater.updateRounds(2777); } @Test public void updateAllRoundsTest() { APIFootballUpdater updater = new APIFootballUpdater(); // updater.updateAllRounds(); } }