Skip to content
Snippets Groups Projects
Commit 74575555 authored by a.croix's avatar a.croix
Browse files

Add tests for Factory

parent 9f0b3fa8
No related branches found
No related tags found
No related merge requests found
package be.cylab.java.wowa.training;
import org.junit.jupiter.api.Test;
import static org.junit.jupiter.api.Assertions.*;
class FactoryTest {
@Test
void testCreateSolutionObject() {
Factory fact = new Factory(new SolutionDistance(5));
AbstractSolution solution = fact.createSolutionObject(5);
assertTrue(solution instanceof SolutionDistance);
Factory fact2 = new Factory(new SolutionAUC(5));
AbstractSolution solution2 = fact2.createSolutionObject(5);
assertTrue(solution2 instanceof SolutionAUC);
}
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment