use of org.evosuite.symbolic.expr.Constraint in project evosuite by EvoSuite.
the class TestSolverFloats method testMod.
public static void testMod(Solver solver) throws SecurityException, NoSuchMethodException, SolverTimeoutException {
DefaultTestCase tc = buildTestCaseFloatMod();
Collection<Constraint<?>> constraints = DefaultTestCaseConcolicExecutor.execute(tc);
Map<String, Object> solution = solve(solver, constraints);
assertNotNull(solution);
Double var0 = (Double) solution.get("var0");
assertEquals(var0.doubleValue(), 2.2 % 2.0, DELTA);
}
use of org.evosuite.symbolic.expr.Constraint in project evosuite by EvoSuite.
the class TestSolverMathFloat method testTrigonometry.
public static Map<String, Object> testTrigonometry(Solver solver) throws SecurityException, NoSuchMethodException, SolverTimeoutException {
DefaultTestCase tc = buildTestCaseFloatTrigonometry();
Collection<Constraint<?>> constraints = DefaultTestCaseConcolicExecutor.execute(tc);
Map<String, Object> solution = solve(solver, constraints);
return solution;
}
use of org.evosuite.symbolic.expr.Constraint in project evosuite by EvoSuite.
the class TestSolverRegex method testRepeatN.
public static Map<String, Object> testRepeatN(CVC4Solver solver) throws SecurityException, NoSuchMethodException, SolverTimeoutException {
DefaultTestCase tc = buildRepeatN();
Collection<Constraint<?>> constraints = DefaultTestCaseConcolicExecutor.execute(tc);
Map<String, Object> solution = solve(solver, constraints);
return solution;
}
use of org.evosuite.symbolic.expr.Constraint in project evosuite by EvoSuite.
the class TestSolverRegex method testOptional.
public static Map<String, Object> testOptional(CVC4Solver solver) throws SecurityException, NoSuchMethodException, SolverTimeoutException {
DefaultTestCase tc = buildTestOptional();
Collection<Constraint<?>> constraints = DefaultTestCaseConcolicExecutor.execute(tc);
Map<String, Object> solution = solve(solver, constraints);
return solution;
}
use of org.evosuite.symbolic.expr.Constraint in project evosuite by EvoSuite.
the class TestSolverRegex method testIntersection.
public static Map<String, Object> testIntersection(CVC4Solver solver) throws SecurityException, NoSuchMethodException, SolverTimeoutException {
DefaultTestCase tc = buildIntersection();
Collection<Constraint<?>> constraints = DefaultTestCaseConcolicExecutor.execute(tc);
Map<String, Object> solution = solve(solver, constraints);
return solution;
}
Aggregations