Skip to content

Commit

Permalink
Fixed tests after rebasing with latest develop
Browse files Browse the repository at this point in the history
  • Loading branch information
jmdelfa committed Apr 5, 2024
1 parent 87a1df5 commit 6ef16e5
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -274,11 +274,12 @@ void schedulingCoexistenceGoal() throws IOException {
void schedulingCoexistenceGoalWithAnchor() throws IOException {
// Setup: Add Goal and Activities
ArrayList<Integer> anchors = insertAnchorActivities();
final int coexistenceGoalId = hasura.insertSchedulingGoal(
/*final int coexistenceGoalId = hasura.insertSchedulingGoal(
"Coexistence Scheduling Test Goal",
modelId,
coexistenceGoalWithAnchorsDefinition);
hasura.createSchedulingSpecGoal(coexistenceGoalId, schedulingSpecId, 0);
coexistenceGoalWithAnchorsDefinition);*/
hasura.createSchedulingSpecGoal("Coexistence Scheduling Test Goal", coexistenceGoalWithAnchorsDefinition, schedulingSpecId, 0);


try {
// Schedule and get Plan
Expand All @@ -303,7 +304,7 @@ void schedulingCoexistenceGoalWithAnchor() throws IOException {

} finally {
// Teardown: Delete Goal
hasura.deleteSchedulingGoal(coexistenceGoalId);
hasura.deleteSchedulingGoal(schedulingSpecId);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -464,7 +464,7 @@ void testCoexistenceGoalWithAnchors() {
true
)
),
List.of(new SchedulingGoal(new GoalId(0L), """
List.of(new SchedulingGoal(new GoalId(0L, 0L), """
export default () => Goal.CoexistenceGoal({
persistentAnchor: PersistentTimeAnchor.START,
forEach: ActivityExpression.ofType(ActivityTypes.BiteBanana),
Expand All @@ -476,7 +476,7 @@ export default () => Goal.CoexistenceGoal({
PLANNING_HORIZON);

assertEquals(1, results.scheduleResults.goalResults().size());
final var goalResult = results.scheduleResults.goalResults().get(new GoalId(0L));
final var goalResult = results.scheduleResults.goalResults().get(new GoalId(0L, 0L));

assertTrue(goalResult.satisfied());
assertEquals(0, goalResult.createdActivities().size());
Expand Down

0 comments on commit 6ef16e5

Please sign in to comment.