create FactoryTest

This commit is contained in:
Andrin Fassbind 2022-05-13 22:35:01 +02:00
parent df3fc5df2d
commit 7f8de3e8f1
2 changed files with 28 additions and 2 deletions

View File

@ -117,8 +117,6 @@ public class Factory {
innerVbox.getChildren().add(label);
}
}
public void resetFooter(BorderPane pane,boolean error) {

View File

@ -0,0 +1,28 @@
package ch.zhaw.projekt2.turnierverwaltung;
import javafx.scene.layout.BorderPane;
import javafx.scene.layout.Pane;
import org.junit.jupiter.api.DisplayName;
import org.junit.jupiter.api.Test;
import org.mockito.InOrder;
import org.mockito.Mockito;
import static org.mockito.Mockito.inOrder;
public class FactoryTest {
private Factory factory;
@Test
@DisplayName("Test method calls")
void checkMethodCalls() {
FileIO fileIO = Mockito.mock(FileIO.class);
TournamentDecorator td = Mockito.mock(TournamentDecorator.class);
LanguageConfigurator lc = Mockito.mock(LanguageConfigurator.class);
BorderPane pane = Mockito.mock(BorderPane.class);
factory = new Factory(fileIO,td,lc);
InOrder order = inOrder(fileIO,td,lc);
factory.showTournamentList(pane);
}
}