Skip to content

Commit

Permalink
Development: Fix architecture tests for exam deletion summary (#9458)
Browse files Browse the repository at this point in the history
  • Loading branch information
ole-ve authored Oct 12, 2024
1 parent 491e368 commit 8045a7f
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,6 @@ public ResponseEntity<Void> deleteCourse(@PathVariable long courseId) {
* @return the ResponseEntity with status 200 (OK) and the deletion summary in the body
*/
@GetMapping("courses/{courseId}/deletion-summary")
@EnforceAdmin
public ResponseEntity<CourseDeletionSummaryDTO> getDeletionSummary(@PathVariable long courseId) {
log.debug("REST request to get deletion summary course: {}", courseId);
final Course course = courseRepository.findByIdWithEagerExercisesElseThrow(courseId);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
import de.tum.cit.aet.artemis.programming.domain.ProgrammingExercise;
import de.tum.cit.aet.artemis.programming.domain.ProgrammingExerciseStudentParticipation;
import de.tum.cit.aet.artemis.programming.domain.build.BuildJob;
import de.tum.cit.aet.artemis.programming.repository.BuildJobRepository;
import de.tum.cit.aet.artemis.programming.test_repository.BuildJobTestRepository;
import de.tum.cit.aet.artemis.programming.util.ProgrammingExerciseFactory;
import de.tum.cit.aet.artemis.shared.base.AbstractSpringIntegrationLocalCILocalVCTest;
import de.tum.cit.aet.artemis.text.domain.TextSubmission;
Expand All @@ -61,7 +61,7 @@ class CourseServiceTest extends AbstractSpringIntegrationLocalCILocalVCTest {
private StudentParticipationTestRepository studentParticipationRepo;

@Autowired
private BuildJobRepository buildJobRepo;
private BuildJobTestRepository buildJobRepo;

@Autowired
private UserUtilService userUtilService;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,16 @@
import de.tum.cit.aet.artemis.exam.domain.Exam;
import de.tum.cit.aet.artemis.exam.domain.StudentExam;
import de.tum.cit.aet.artemis.exam.dto.ExamDeletionSummaryDTO;
import de.tum.cit.aet.artemis.exam.repository.StudentExamRepository;
import de.tum.cit.aet.artemis.exam.service.ExamSessionService;
import de.tum.cit.aet.artemis.exam.test_repository.StudentExamTestRepository;
import de.tum.cit.aet.artemis.exam.util.ExamUtilService;
import de.tum.cit.aet.artemis.exercise.domain.ExerciseType;
import de.tum.cit.aet.artemis.exercise.domain.participation.Participation;
import de.tum.cit.aet.artemis.exercise.participation.util.ParticipationUtilService;
import de.tum.cit.aet.artemis.programming.domain.ProgrammingExercise;
import de.tum.cit.aet.artemis.programming.domain.ProgrammingExerciseStudentParticipation;
import de.tum.cit.aet.artemis.programming.domain.build.BuildJob;
import de.tum.cit.aet.artemis.programming.repository.BuildJobRepository;
import de.tum.cit.aet.artemis.programming.test_repository.BuildJobTestRepository;
import de.tum.cit.aet.artemis.shared.base.AbstractSpringIntegrationIndependentTest;

@TestInstance(TestInstance.Lifecycle.PER_CLASS)
Expand All @@ -43,13 +43,13 @@ class ExamDeletionIntegrationTest extends AbstractSpringIntegrationIndependentTe
private ExamSessionService examSessionService;

@Autowired
private StudentExamRepository studentExamRepository;
private StudentExamTestRepository studentExamRepository;

@Autowired
private ParticipationUtilService participationUtilService;

@Autowired
private BuildJobRepository buildJobRepository;
private BuildJobTestRepository buildJobRepository;

private static final int NUMBER_OF_STUDENTS = 4;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@
import de.tum.cit.aet.artemis.communication.domain.Post;
import de.tum.cit.aet.artemis.communication.domain.conversation.Channel;
import de.tum.cit.aet.artemis.communication.repository.AnswerPostRepository;
import de.tum.cit.aet.artemis.communication.repository.PostRepository;
import de.tum.cit.aet.artemis.communication.test_repository.ConversationTestRepository;
import de.tum.cit.aet.artemis.communication.test_repository.PostTestRepository;
import de.tum.cit.aet.artemis.communication.util.ConversationFactory;
import de.tum.cit.aet.artemis.core.domain.Course;
import de.tum.cit.aet.artemis.core.domain.Language;
Expand Down Expand Up @@ -137,7 +137,7 @@ public class ExamUtilService {
private ConversationTestRepository conversationRepository;

@Autowired
private PostRepository postRepository;
private PostTestRepository postRepository;

@Autowired
private AnswerPostRepository answerPostRepository;
Expand Down

0 comments on commit 8045a7f

Please sign in to comment.