Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jxjj committed Sep 17, 2024
1 parent 3cd11a5 commit 6d6363e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion app/Traits/SectionEnrollmentTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ protected function getSectionId() {
return join('-', [
'db',
$this->course_section_id ?? $this->id,
$this->TERM,
$this->term_id,
]);
}

Expand Down
4 changes: 2 additions & 2 deletions tests/Feature/api/course-planning/CoursePlanningApiTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@
expect($res->status())->toBe(200);
expect($res->json())->not()->toBeEmpty();
expect($res->json()[0])->toEqual([
'id' => 'sis-87153',
'id' => 'sis-AFRO-3654-001-1195',
'courseId' => 'AFRO-3654',
'classNumber' => 87153,
'dbId' => null,
Expand Down Expand Up @@ -237,7 +237,7 @@
// expect that the unofficial section is included
$sectionFromApi = collect($res->json())->firstWhere('courseId', $section->course_id);
expect($sectionFromApi)->toEqual([
'id' => "db-{$section->id}",
'id' => "db-{$section->id}-{$section->term_id}",
'dbId' => $section->id,
'groupId' => $section->group_id,
'courseId' => $section->course_id,
Expand Down

0 comments on commit 6d6363e

Please sign in to comment.