Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package menu;
- import controller.result.GenerateCompetitors;
- import controller.result.IO;
- import controller.result.ParseTimes;
- import java.io.IOException;
- import model.result.RaceResultList;
- import org.junit.Before;
- import org.junit.Test;
- public class IOTest {
- IO io;
- ParseTimes starTime, finishTime;
- GenerateCompetitors competitors;
- RaceResultList rrl;
- @Before
- public void setUp() throws Exception {
- io = new IO();
- io.parseNameFile("textfilesForTest/testNamnfil.txt")
- .parseStartFile("textfilesForTest/testStarttider.txt")
- .parseStartFile("textfilesForTest/testStarttider2.txt")
- .parseFinishFile("textfilesForTest/testMaltider.txt")
- .parseFinishFile("textfilesForTest/testMaltider2.txt");
- }
- @Test
- public void printResults() throws IOException {
- io.printResults(
- "StartNr; Namn; Totaltid; Starttid; Måltid", "textfilesForTest/testResultat.txt");
- }
- @Test
- public void testFormattedResult() throws IOException {
- io.eventType("Novemberkåsan 2020");
- io.printResults(
- "StartNr; Namn; Totaltid; Starttid; Måltid", "textfilesForTest/testResultatFormatted.txt");
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement