RosterStudentsController.java

1
package edu.ucsb.cs156.frontiers.controllers;
2
3
import com.fasterxml.jackson.core.JsonProcessingException;
4
import edu.ucsb.cs156.frontiers.entities.Course;
5
import edu.ucsb.cs156.frontiers.entities.RosterStudent;
6
import edu.ucsb.cs156.frontiers.entities.User;
7
import edu.ucsb.cs156.frontiers.enums.InsertStatus;
8
import edu.ucsb.cs156.frontiers.enums.OrgStatus;
9
import edu.ucsb.cs156.frontiers.enums.RosterStatus;
10
import edu.ucsb.cs156.frontiers.errors.EntityNotFoundException;
11
import edu.ucsb.cs156.frontiers.errors.NoLinkedOrganizationException;
12
import edu.ucsb.cs156.frontiers.jobs.UpdateOrgMembershipJob;
13
import edu.ucsb.cs156.frontiers.models.RosterStudentDTO;
14
import edu.ucsb.cs156.frontiers.models.UpsertResponse;
15
import edu.ucsb.cs156.frontiers.repositories.CourseRepository;
16
import edu.ucsb.cs156.frontiers.repositories.RosterStudentRepository;
17
import edu.ucsb.cs156.frontiers.services.CurrentUserService;
18
import edu.ucsb.cs156.frontiers.services.OrganizationMemberService;
19
import edu.ucsb.cs156.frontiers.services.UpdateUserService;
20
import edu.ucsb.cs156.frontiers.utilities.CanonicalFormConverter;
21
import edu.ucsb.cs156.jobs.entities.Job;
22
import edu.ucsb.cs156.jobs.services.JobService;
23
import io.swagger.v3.oas.annotations.Operation;
24
import io.swagger.v3.oas.annotations.Parameter;
25
import io.swagger.v3.oas.annotations.tags.Tag;
26
import java.security.NoSuchAlgorithmException;
27
import java.security.spec.InvalidKeySpecException;
28
import java.util.ArrayList;
29
import java.util.List;
30
import java.util.Optional;
31
import lombok.extern.slf4j.Slf4j;
32
import org.springframework.beans.factory.annotation.Autowired;
33
import org.springframework.http.HttpStatus;
34
import org.springframework.http.ResponseEntity;
35
import org.springframework.security.access.AccessDeniedException;
36
import org.springframework.security.access.prepost.PreAuthorize;
37
import org.springframework.transaction.annotation.Transactional;
38
import org.springframework.web.bind.annotation.DeleteMapping;
39
import org.springframework.web.bind.annotation.GetMapping;
40
import org.springframework.web.bind.annotation.PathVariable;
41
import org.springframework.web.bind.annotation.PostMapping;
42
import org.springframework.web.bind.annotation.PutMapping;
43
import org.springframework.web.bind.annotation.RequestMapping;
44
import org.springframework.web.bind.annotation.RequestParam;
45
import org.springframework.web.bind.annotation.RestController;
46
import org.springframework.web.server.ResponseStatusException;
47
48
@Tag(name = "RosterStudents")
49
@RequestMapping("/api/rosterstudents")
50
@RestController
51
@Slf4j
52
public class RosterStudentsController extends ApiController {
53
54
  @Autowired private JobService jobService;
55
  @Autowired private OrganizationMemberService organizationMemberService;
56
57
  @Autowired private RosterStudentRepository rosterStudentRepository;
58
59
  @Autowired private CourseRepository courseRepository;
60
61
  @Autowired private UpdateUserService updateUserService;
62
63
  @Autowired private CurrentUserService currentUserService;
64
65
  /**
66
   * This method creates a new RosterStudent. It is important to keep the code in this method
67
   * consistent with the code for adding multiple roster students from a CSV
68
   *
69
   * @return the created RosterStudent
70
   */
71
  @Operation(summary = "Create a new roster student")
72
  @PreAuthorize("@CourseSecurity.hasManagePermissions(#root, #courseId)")
73
  @PostMapping("/post")
74
  public ResponseEntity<UpsertResponse> postRosterStudent(
75
      @Parameter(name = "studentId") @RequestParam String studentId,
76
      @Parameter(name = "firstName") @RequestParam String firstName,
77
      @Parameter(name = "lastName") @RequestParam String lastName,
78
      @Parameter(name = "email") @RequestParam String email,
79
      @Parameter(name = "courseId") @RequestParam Long courseId,
80
      @Parameter(name = "section") @RequestParam(required = false) String section)
81
      throws EntityNotFoundException {
82
83
    // Get Course or else throw an error
84
85
    Course course =
86
        courseRepository
87
            .findById(courseId)
88 1 1. lambda$postRosterStudent$0 : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$postRosterStudent$0 → KILLED
            .orElseThrow(() -> new EntityNotFoundException(Course.class, courseId));
89
90
    RosterStudent rosterStudent =
91
        RosterStudent.builder()
92
            .studentId(studentId)
93
            .firstName(firstName)
94
            .lastName(lastName)
95
            .email(email.strip())
96 1 1. postRosterStudent : negated conditional → KILLED
            .section(section != null ? section : "")
97
            .build();
98
99
    UpsertResponse upsertResponse = upsertStudent(rosterStudent, course, RosterStatus.MANUAL);
100 1 1. postRosterStudent : negated conditional → KILLED
    if (upsertResponse.getInsertStatus() == InsertStatus.REJECTED) {
101 1 1. postRosterStudent : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::postRosterStudent → KILLED
      return ResponseEntity.status(HttpStatus.CONFLICT).body(upsertResponse);
102
    } else {
103
      rosterStudent = rosterStudentRepository.save(upsertResponse.rosterStudent());
104 1 1. postRosterStudent : removed call to edu/ucsb/cs156/frontiers/services/UpdateUserService::attachUserToRosterStudent → KILLED
      updateUserService.attachUserToRosterStudent(rosterStudent);
105 1 1. postRosterStudent : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::postRosterStudent → KILLED
      return ResponseEntity.ok(upsertResponse);
106
    }
107
  }
108
109
  /**
110
   * This method returns a list of roster students for a given course.
111
   *
112
   * @return a list of all courses.
113
   */
114
  @Operation(summary = "List all roster students for a course")
115
  @PreAuthorize("@CourseSecurity.hasManagePermissions(#root, #courseId)")
116
  @GetMapping("/course/{courseId}")
117
  public Iterable<RosterStudentDTO> rosterStudentForCourse(
118
      @Parameter(name = "courseId") @PathVariable Long courseId) throws EntityNotFoundException {
119
    courseRepository
120
        .findById(courseId)
121 1 1. lambda$rosterStudentForCourse$0 : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$rosterStudentForCourse$0 → KILLED
        .orElseThrow(() -> new EntityNotFoundException(Course.class, courseId));
122
    Iterable<RosterStudent> rosterStudents =
123
        rosterStudentRepository.findByCourseIdOrderByFirstNameAscLastNameAscIgnoreCase(courseId);
124
    Iterable<RosterStudentDTO> rosterStudentDTOs =
125
        () ->
126 1 1. lambda$rosterStudentForCourse$1 : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$rosterStudentForCourse$1 → KILLED
            java.util.stream.StreamSupport.stream(rosterStudents.spliterator(), false)
127
                .map(RosterStudentDTO::new)
128
                .iterator();
129 1 1. rosterStudentForCourse : replaced return value with Collections.emptyList for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::rosterStudentForCourse → KILLED
    return rosterStudentDTOs;
130
  }
131
132
  public static UpsertResponse upsertStudent(
133
      RosterStudent student, Course course, RosterStatus rosterStatus) {
134
    String convertedEmail = CanonicalFormConverter.convertToValidEmail(student.getEmail()).strip();
135
    Optional<RosterStudent> existingStudent =
136
        course.getRosterStudents().stream()
137
            .filter(
138 2 1. lambda$upsertStudent$0 : replaced boolean return with true for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$upsertStudent$0 → KILLED
2. lambda$upsertStudent$0 : replaced boolean return with false for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$upsertStudent$0 → KILLED
                filteringStudent -> student.getStudentId().equals(filteringStudent.getStudentId()))
139
            .findFirst();
140
    Optional<RosterStudent> existingStudentByEmail =
141
        course.getRosterStudents().stream()
142 2 1. lambda$upsertStudent$1 : replaced boolean return with false for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$upsertStudent$1 → KILLED
2. lambda$upsertStudent$1 : replaced boolean return with true for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$upsertStudent$1 → KILLED
            .filter(filteringStudent -> convertedEmail.equals(filteringStudent.getEmail()))
143
            .findFirst();
144 2 1. upsertStudent : negated conditional → KILLED
2. upsertStudent : negated conditional → KILLED
    if (existingStudent.isPresent() && existingStudentByEmail.isPresent()) {
145
      // Compare by identity rather than by id: during a CSV upload, a newly inserted student
146
      // that has not yet been saved (id == null) is added to the course's roster list, and a
147
      // duplicate row later in the same file must match it without throwing an NPE.
148 1 1. upsertStudent : negated conditional → KILLED
      if (existingStudent.get() == existingStudentByEmail.get()) {
149
        RosterStudent existingStudentObj = existingStudent.get();
150 1 1. upsertStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setRosterStatus → KILLED
        existingStudentObj.setRosterStatus(rosterStatus);
151 1 1. upsertStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setFirstName → KILLED
        existingStudentObj.setFirstName(student.getFirstName());
152 1 1. upsertStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setLastName → KILLED
        existingStudentObj.setLastName(student.getLastName());
153 1 1. upsertStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setSection → KILLED
        existingStudentObj.setSection(student.getSection());
154 1 1. upsertStudent : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::upsertStudent → KILLED
        return new UpsertResponse(InsertStatus.UPDATED, existingStudentObj);
155
      } else {
156 1 1. upsertStudent : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::upsertStudent → KILLED
        return new UpsertResponse(InsertStatus.REJECTED, student);
157
      }
158 2 1. upsertStudent : negated conditional → KILLED
2. upsertStudent : negated conditional → KILLED
    } else if (existingStudent.isPresent() || existingStudentByEmail.isPresent()) {
159
      RosterStudent existingStudentObj =
160 1 1. upsertStudent : negated conditional → KILLED
          existingStudent.isPresent() ? existingStudent.get() : existingStudentByEmail.get();
161 1 1. upsertStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setRosterStatus → KILLED
      existingStudentObj.setRosterStatus(rosterStatus);
162 1 1. upsertStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setFirstName → KILLED
      existingStudentObj.setFirstName(student.getFirstName());
163 1 1. upsertStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setLastName → KILLED
      existingStudentObj.setLastName(student.getLastName());
164 1 1. upsertStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setSection → KILLED
      existingStudentObj.setSection(student.getSection());
165 1 1. upsertStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setEmail → KILLED
      existingStudentObj.setEmail(convertedEmail);
166 1 1. upsertStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setStudentId → KILLED
      existingStudentObj.setStudentId(student.getStudentId());
167 1 1. upsertStudent : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::upsertStudent → KILLED
      return new UpsertResponse(InsertStatus.UPDATED, existingStudentObj);
168
    } else {
169 1 1. upsertStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setCourse → KILLED
      student.setCourse(course);
170 1 1. upsertStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setEmail → KILLED
      student.setEmail(convertedEmail);
171 1 1. upsertStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setRosterStatus → KILLED
      student.setRosterStatus(rosterStatus);
172
      // if an installationID exists, orgStatus should be set to JOINCOURSE. if it doesn't exist
173
      // (null), set orgStatus to PENDING.
174 1 1. upsertStudent : negated conditional → KILLED
      if (course.getInstallationId() != null) {
175 1 1. upsertStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setOrgStatus → KILLED
        student.setOrgStatus(OrgStatus.JOINCOURSE);
176
      } else {
177 1 1. upsertStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setOrgStatus → KILLED
        student.setOrgStatus(OrgStatus.PENDING);
178
      }
179 1 1. upsertStudent : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::upsertStudent → KILLED
      return new UpsertResponse(InsertStatus.INSERTED, student);
180
    }
181
  }
182
183
  @PreAuthorize("@CourseSecurity.hasManagePermissions(#root, #courseId)")
184
  @PostMapping("/updateCourseMembership")
185
  public Job updateCourseMembership(
186
      @Parameter(name = "courseId", description = "Course ID") @RequestParam Long courseId)
187
      throws NoSuchAlgorithmException, InvalidKeySpecException, JsonProcessingException {
188
    Course course =
189
        courseRepository
190
            .findById(courseId)
191 1 1. lambda$updateCourseMembership$0 : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$updateCourseMembership$0 → KILLED
            .orElseThrow(() -> new EntityNotFoundException(Course.class, courseId));
192 2 1. updateCourseMembership : negated conditional → KILLED
2. updateCourseMembership : negated conditional → KILLED
    if (course.getInstallationId() == null || course.getOrgName() == null) {
193
      throw new NoLinkedOrganizationException(course.getCourseName());
194
    } else {
195
      UpdateOrgMembershipJob job =
196
          UpdateOrgMembershipJob.builder()
197
              .rosterStudentRepository(rosterStudentRepository)
198
              .organizationMemberService(organizationMemberService)
199
              .course(course)
200
              .build();
201
202 1 1. updateCourseMembership : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::updateCourseMembership → KILLED
      return jobService.runAsJob(job);
203
    }
204
  }
205
206
  @Operation(
207
      summary =
208
          "Allow roster student to join a course by generating an invitation to the linked Github Org")
209
  @PreAuthorize("hasRole('ROLE_USER')")
210
  @PutMapping("/joinCourse")
211
  public ResponseEntity<String> joinCourseOnGitHub(
212
      @Parameter(
213
              name = "rosterStudentId",
214
              description = "Roster Student joining a course on GitHub")
215
          @RequestParam
216
          Long rosterStudentId)
217
      throws NoSuchAlgorithmException, InvalidKeySpecException, JsonProcessingException {
218
219
    User currentUser = currentUserService.getUser();
220
    RosterStudent rosterStudent =
221
        rosterStudentRepository
222
            .findById(rosterStudentId)
223 1 1. lambda$joinCourseOnGitHub$0 : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$joinCourseOnGitHub$0 → KILLED
            .orElseThrow(() -> new EntityNotFoundException(RosterStudent.class, rosterStudentId));
224
225 2 1. joinCourseOnGitHub : negated conditional → KILLED
2. joinCourseOnGitHub : negated conditional → KILLED
    if (rosterStudent.getUser() == null || currentUser.getId() != rosterStudent.getUser().getId()) {
226
      throw new AccessDeniedException("User not authorized join the course as this roster student");
227
    }
228
229 1 1. joinCourseOnGitHub : negated conditional → KILLED
    if (rosterStudent.getRosterStatus() == RosterStatus.DROPPED) {
230
      throw new AccessDeniedException(
231
          "You have dropped this course. Please contact your instructor.");
232
    }
233
234 1 1. joinCourseOnGitHub : negated conditional → KILLED
    if (rosterStudent.getGithubId() != null
235 1 1. joinCourseOnGitHub : negated conditional → KILLED
        && rosterStudent.getGithubLogin() != null
236 1 1. joinCourseOnGitHub : negated conditional → KILLED
        && (rosterStudent.getOrgStatus() == OrgStatus.MEMBER
237 1 1. joinCourseOnGitHub : negated conditional → KILLED
            || rosterStudent.getOrgStatus() == OrgStatus.OWNER)) {
238 1 1. joinCourseOnGitHub : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::joinCourseOnGitHub → KILLED
      return ResponseEntity.badRequest()
239
          .body("This user has already linked a Github account to this course.");
240
    }
241
242 1 1. joinCourseOnGitHub : negated conditional → KILLED
    if (rosterStudent.getCourse().getOrgName() == null
243 1 1. joinCourseOnGitHub : negated conditional → KILLED
        || rosterStudent.getCourse().getInstallationId() == null) {
244 1 1. joinCourseOnGitHub : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::joinCourseOnGitHub → KILLED
      return ResponseEntity.badRequest()
245
          .body("Course has not been set up. Please ask your instructor for help.");
246
    }
247 1 1. joinCourseOnGitHub : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setGithubId → KILLED
    rosterStudent.setGithubId(currentUser.getGithubId());
248 1 1. joinCourseOnGitHub : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setGithubLogin → KILLED
    rosterStudent.setGithubLogin(currentUser.getGithubLogin());
249
    OrgStatus status = organizationMemberService.inviteOrganizationMember(rosterStudent);
250 1 1. joinCourseOnGitHub : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setOrgStatus → KILLED
    rosterStudent.setOrgStatus(status);
251
    rosterStudentRepository.save(rosterStudent);
252 1 1. joinCourseOnGitHub : negated conditional → KILLED
    if (status == OrgStatus.INVITED) {
253 1 1. joinCourseOnGitHub : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::joinCourseOnGitHub → KILLED
      return ResponseEntity.accepted().body("Successfully invited student to Organization");
254 2 1. joinCourseOnGitHub : negated conditional → KILLED
2. joinCourseOnGitHub : negated conditional → KILLED
    } else if (status == OrgStatus.MEMBER || status == OrgStatus.OWNER) {
255 1 1. joinCourseOnGitHub : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::joinCourseOnGitHub → KILLED
      return ResponseEntity.accepted()
256
          .body("Already in organization - set status to %s".formatted(status.toString()));
257
    } else {
258 1 1. joinCourseOnGitHub : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::joinCourseOnGitHub → KILLED
      return ResponseEntity.internalServerError().body("Could not invite student to Organization");
259
    }
260
  }
261
262
  @Operation(summary = "Get Associated Roster Students with a User")
263
  @PreAuthorize("hasRole('ROLE_USER')")
264
  @GetMapping("/associatedRosterStudents")
265
  public Iterable<RosterStudent> getAssociatedRosterStudents() {
266
    User currentUser = currentUserService.getUser();
267
    Iterable<RosterStudent> rosterStudents = rosterStudentRepository.findAllByUser((currentUser));
268 1 1. getAssociatedRosterStudents : replaced return value with Collections.emptyList for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::getAssociatedRosterStudents → KILLED
    return rosterStudents;
269
  }
270
271
  @Operation(summary = "Update a roster student")
272
  @PreAuthorize("@CourseSecurity.hasRosterStudentManagementPermissions(#root, #id)")
273
  @PutMapping("/update")
274
  public RosterStudent updateRosterStudent(
275
      @Parameter(name = "id") @RequestParam Long id,
276
      @Parameter(name = "firstName") @RequestParam(required = false) String firstName,
277
      @Parameter(name = "lastName") @RequestParam(required = false) String lastName,
278
      @Parameter(name = "studentId") @RequestParam(required = false) String studentId,
279
      @Parameter(name = "section") @RequestParam(required = false) String section)
280
      throws EntityNotFoundException {
281
282 3 1. updateRosterStudent : negated conditional → KILLED
2. updateRosterStudent : negated conditional → KILLED
3. updateRosterStudent : negated conditional → KILLED
    if (firstName == null
283
        || lastName == null
284
        || studentId == null
285 1 1. updateRosterStudent : negated conditional → KILLED
        || firstName.trim().isEmpty()
286 1 1. updateRosterStudent : negated conditional → KILLED
        || lastName.trim().isEmpty()
287 1 1. updateRosterStudent : negated conditional → KILLED
        || studentId.trim().isEmpty()) {
288
      throw new ResponseStatusException(HttpStatus.BAD_REQUEST, "Required fields cannot be empty");
289
    }
290
291
    RosterStudent rosterStudent =
292
        rosterStudentRepository
293
            .findById(id)
294 1 1. lambda$updateRosterStudent$0 : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$updateRosterStudent$0 → KILLED
            .orElseThrow(() -> new EntityNotFoundException(RosterStudent.class, id));
295
296 1 1. updateRosterStudent : negated conditional → KILLED
    if (!rosterStudent.getStudentId().trim().equals(studentId.trim())) {
297
      Optional<RosterStudent> existingStudent =
298
          rosterStudentRepository.findByCourseIdAndStudentId(
299
              rosterStudent.getCourse().getId(), studentId.trim());
300 1 1. updateRosterStudent : negated conditional → KILLED
      if (existingStudent.isPresent()) {
301
        throw new ResponseStatusException(
302
            HttpStatus.BAD_REQUEST, "Student ID already exists in this course");
303
      }
304
    }
305
306 1 1. updateRosterStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setFirstName → KILLED
    rosterStudent.setFirstName(firstName.trim());
307 1 1. updateRosterStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setLastName → KILLED
    rosterStudent.setLastName(lastName.trim());
308 1 1. updateRosterStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setStudentId → KILLED
    rosterStudent.setStudentId(studentId.trim());
309
310 1 1. updateRosterStudent : negated conditional → KILLED
    if (section != null) {
311 1 1. updateRosterStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setSection → KILLED
      rosterStudent.setSection(section.trim());
312
    }
313
314 1 1. updateRosterStudent : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::updateRosterStudent → KILLED
    return rosterStudentRepository.save(rosterStudent);
315
  }
316
317
  @Operation(
318
      summary = "Restore a roster student",
319
      description = "Makes a student who previously dropped the course able to join and interact")
320
  @PreAuthorize("@CourseSecurity.hasRosterStudentManagementPermissions(#root, #id)")
321
  @PutMapping("/restore")
322
  public RosterStudent restoreRosterStudent(@Parameter(name = "id") @RequestParam Long id)
323
      throws EntityNotFoundException {
324
    RosterStudent rosterStudent =
325
        rosterStudentRepository
326
            .findById(id)
327 1 1. lambda$restoreRosterStudent$0 : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$restoreRosterStudent$0 → KILLED
            .orElseThrow(() -> new EntityNotFoundException(RosterStudent.class, id));
328 1 1. restoreRosterStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setRosterStatus → KILLED
    rosterStudent.setRosterStatus(RosterStatus.MANUAL);
329 1 1. restoreRosterStudent : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::restoreRosterStudent → KILLED
    return rosterStudentRepository.save(rosterStudent);
330
  }
331
332
  /** Outcome of the optional GitHub organization removal step when deleting a roster student. */
333
  public record OrgRemovalResult(boolean attempted, boolean successful, String errorMessage) {}
334
335
  /** Summary returned when purging all dropped roster students from a course. */
336
  public record PurgeDroppedResponse(
337
      int deleted, int removedFromOrg, List<String> orgRemovalErrors) {}
338
339
  @Operation(summary = "Delete a roster student")
340
  @PreAuthorize("@CourseSecurity.hasRosterStudentManagementPermissions(#root, #id)")
341
  @DeleteMapping("/delete")
342
  @Transactional
343
  public ResponseEntity<String> deleteRosterStudent(
344
      @Parameter(name = "id") @RequestParam Long id,
345
      @Parameter(
346
              name = "removeFromOrg",
347
              description = "Whether to remove student from GitHub organization")
348
          @RequestParam(defaultValue = "true")
349
          boolean removeFromOrg)
350
      throws EntityNotFoundException {
351
    RosterStudent rosterStudent =
352
        rosterStudentRepository
353
            .findById(id)
354 1 1. lambda$deleteRosterStudent$0 : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$deleteRosterStudent$0 → KILLED
            .orElseThrow(() -> new EntityNotFoundException(RosterStudent.class, id));
355
356
    OrgRemovalResult result = deleteSingleRosterStudent(rosterStudent, removeFromOrg);
357
358 1 1. deleteRosterStudent : negated conditional → KILLED
    if (!result.attempted()) {
359 1 1. deleteRosterStudent : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::deleteRosterStudent → KILLED
      return ResponseEntity.ok(
360
          "Successfully deleted roster student and removed him/her from the course list");
361 1 1. deleteRosterStudent : negated conditional → KILLED
    } else if (result.successful()) {
362 1 1. deleteRosterStudent : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::deleteRosterStudent → KILLED
      return ResponseEntity.ok(
363
          "Successfully deleted roster student and removed him/her from the course list and organization");
364
    } else {
365 1 1. deleteRosterStudent : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::deleteRosterStudent → KILLED
      return ResponseEntity.ok(
366
          "Successfully deleted roster student but there was an error removing them from the course organization: "
367
              + result.errorMessage());
368
    }
369
  }
370
371
  @Operation(
372
      summary = "Purge all dropped roster students from a course",
373
      description =
374
          "Deletes every roster student in the course whose roster status is DROPPED, optionally removing them from the GitHub organization")
375
  @PreAuthorize("@CourseSecurity.hasManagePermissions(#root, #courseId)")
376
  @DeleteMapping("/purgeDropped")
377
  @Transactional
378
  public PurgeDroppedResponse purgeDroppedRosterStudents(
379
      @Parameter(name = "courseId") @RequestParam Long courseId,
380
      @Parameter(
381
              name = "removeFromOrg",
382
              description = "Whether to remove the students from the GitHub organization")
383
          @RequestParam(defaultValue = "true")
384
          boolean removeFromOrg)
385
      throws EntityNotFoundException {
386
    courseRepository
387
        .findById(courseId)
388 1 1. lambda$purgeDroppedRosterStudents$0 : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$purgeDroppedRosterStudents$0 → KILLED
        .orElseThrow(() -> new EntityNotFoundException(Course.class, courseId));
389
390
    List<RosterStudent> droppedStudents =
391
        new ArrayList<>(
392
            rosterStudentRepository
393
                .findByCourseIdAndRosterStatusInOrderByFirstNameAscLastNameAscIgnoreCase(
394
                    courseId, List.of(RosterStatus.DROPPED)));
395
396
    int deleted = 0;
397
    int removedFromOrg = 0;
398
    List<String> orgRemovalErrors = new ArrayList<>();
399
    for (RosterStudent rosterStudent : droppedStudents) {
400
      OrgRemovalResult result = deleteSingleRosterStudent(rosterStudent, removeFromOrg);
401 1 1. purgeDroppedRosterStudents : Changed increment from 1 to -1 → KILLED
      deleted++;
402 1 1. purgeDroppedRosterStudents : negated conditional → KILLED
      if (result.successful()) {
403 1 1. purgeDroppedRosterStudents : Changed increment from 1 to -1 → KILLED
        removedFromOrg++;
404 1 1. purgeDroppedRosterStudents : negated conditional → KILLED
      } else if (result.attempted()) {
405
        orgRemovalErrors.add(rosterStudent.getEmail() + ": " + result.errorMessage());
406
      }
407
    }
408 1 1. purgeDroppedRosterStudents : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::purgeDroppedRosterStudents → KILLED
    return new PurgeDroppedResponse(deleted, removedFromOrg, orgRemovalErrors);
409
  }
410
411
  /**
412
   * Deletes a single roster student: optionally removes them from the GitHub organization, detaches
413
   * them from any teams and from the course, and deletes the row.
414
   *
415
   * @param rosterStudent the student to delete
416
   * @param removeFromOrg whether to attempt removal from the GitHub organization
417
   * @return the outcome of the organization removal step
418
   */
419
  private OrgRemovalResult deleteSingleRosterStudent(
420
      RosterStudent rosterStudent, boolean removeFromOrg) {
421
    Course course = rosterStudent.getCourse();
422
423
    boolean orgRemovalAttempted = false;
424
    boolean orgRemovalSuccessful = false;
425
    String orgRemovalErrorMessage = null;
426
427
    // Try to remove the student from the organization if they have a GitHub login
428
    // and removeFromOrg parameter is true
429 1 1. deleteSingleRosterStudent : negated conditional → KILLED
    if (removeFromOrg
430 1 1. deleteSingleRosterStudent : negated conditional → KILLED
        && rosterStudent.getGithubLogin() != null
431 1 1. deleteSingleRosterStudent : negated conditional → KILLED
        && course.getOrgName() != null
432 1 1. deleteSingleRosterStudent : negated conditional → KILLED
        && course.getInstallationId() != null) {
433
      orgRemovalAttempted = true;
434
      try {
435 1 1. deleteSingleRosterStudent : removed call to edu/ucsb/cs156/frontiers/services/OrganizationMemberService::removeOrganizationMember → KILLED
        organizationMemberService.removeOrganizationMember(rosterStudent);
436
        orgRemovalSuccessful = true;
437
      } catch (Exception e) {
438
        log.error("Error removing student from organization: {}", e.getMessage());
439
        orgRemovalErrorMessage = e.getMessage();
440
        // Continue with deletion even if organization removal fails
441
      }
442
    }
443
444 1 1. deleteSingleRosterStudent : negated conditional → KILLED
    if (!rosterStudent.getTeamMembers().isEmpty()) {
445
      rosterStudent
446
          .getTeamMembers()
447 1 1. deleteSingleRosterStudent : removed call to java/util/List::forEach → KILLED
          .forEach(
448
              teamMember -> {
449
                teamMember.getTeam().getTeamMembers().remove(teamMember);
450 1 1. lambda$deleteSingleRosterStudent$0 : removed call to edu/ucsb/cs156/frontiers/entities/TeamMember::setTeam → KILLED
                teamMember.setTeam(null);
451
              });
452
    }
453
454
    course.getRosterStudents().remove(rosterStudent);
455 1 1. deleteSingleRosterStudent : removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setCourse → KILLED
    rosterStudent.setCourse(null);
456 1 1. deleteSingleRosterStudent : removed call to edu/ucsb/cs156/frontiers/repositories/RosterStudentRepository::delete → KILLED
    rosterStudentRepository.delete(rosterStudent);
457
458 1 1. deleteSingleRosterStudent : replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::deleteSingleRosterStudent → KILLED
    return new OrgRemovalResult(orgRemovalAttempted, orgRemovalSuccessful, orgRemovalErrorMessage);
459
  }
460
}

Mutations

88

1.1
Location : lambda$postRosterStudent$0
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:test_InstructorCannotPostRosterStudentForCourseThatDoesNotExist()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$postRosterStudent$0 → KILLED

96

1.1
Location : postRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPostRosterStudent_withSection()]
negated conditional → KILLED

100

1.1
Location : postRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:test_post_fails_on_matching()]
negated conditional → KILLED

101

1.1
Location : postRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:test_post_fails_on_matching()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::postRosterStudent → KILLED

104

1.1
Location : postRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPostRosterStudent_emailSanitized()]
removed call to edu/ucsb/cs156/frontiers/services/UpdateUserService::attachUserToRosterStudent → KILLED

105

1.1
Location : postRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPostRosterStudentWithNoInstallationId()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::postRosterStudent → KILLED

121

1.1
Location : lambda$rosterStudentForCourse$0
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:getting_roster_students_for_a_non_existing_course_returns_appropriate_error()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$rosterStudentForCourse$0 → KILLED

126

1.1
Location : lambda$rosterStudentForCourse$1
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testRosterStudentsByCourse()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$rosterStudentForCourse$1 → KILLED

129

1.1
Location : rosterStudentForCourse
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testRosterStudentsByCourse()]
replaced return value with Collections.emptyList for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::rosterStudentForCourse → KILLED

138

1.1
Location : lambda$upsertStudent$0
Killed by : edu.ucsb.cs156.frontiers.controllers.CanvasControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.CanvasControllerTests]/[method:testUploadRosterFromCanvas_manualStudentStaysManual()]
replaced boolean return with true for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$upsertStudent$0 → KILLED

2.2
Location : lambda$upsertStudent$0
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:upsertStudent_rejects_when_unsaved_id_match_and_email_match_differ()]
replaced boolean return with false for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$upsertStudent$0 → KILLED

142

1.1
Location : lambda$upsertStudent$1
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:upsertStudent_rejects_when_unsaved_id_match_and_email_match_differ()]
replaced boolean return with false for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$upsertStudent$1 → KILLED

2.2
Location : lambda$upsertStudent$1
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:upsertStudent_rejects_when_unsaved_id_match_and_email_match_differ()]
replaced boolean return with true for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$upsertStudent$1 → KILLED

144

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:upsertStudent_rejects_when_unsaved_id_match_and_email_match_differ()]
negated conditional → KILLED

2.2
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:upsertStudent_rejects_when_unsaved_id_match_and_email_match_differ()]
negated conditional → KILLED

148

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:upsertStudent_rejects_when_unsaved_id_match_and_email_match_differ()]
negated conditional → KILLED

150

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.CanvasControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.CanvasControllerTests]/[method:testUploadRosterFromCanvas_updatesExistingStudents()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setRosterStatus → KILLED

151

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsCSVControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsCSVControllerTests]/[method:updates_in_upsert_correctly()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setFirstName → KILLED

152

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsCSVControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsCSVControllerTests]/[method:updates_in_upsert_correctly()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setLastName → KILLED

153

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsCSVControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsCSVControllerTests]/[method:updates_in_upsert_correctly()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setSection → KILLED

154

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:upsertStudent_matches_unsaved_student_by_identity_without_npe()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::upsertStudent → KILLED

156

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:upsertStudent_rejects_when_unsaved_id_match_and_email_match_differ()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::upsertStudent → KILLED

158

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPostRosterStudent_withSection()]
negated conditional → KILLED

2.2
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPostRosterStudent_withSection()]
negated conditional → KILLED

160

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpsertStudentUpdatingTheEmail()]
negated conditional → KILLED

161

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpsertStudentUpdatingTheEmail()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setRosterStatus → KILLED

162

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpsertStudentUpdatingTheEmail()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setFirstName → KILLED

163

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpsertStudentUpdatingTheEmail()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setLastName → KILLED

164

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsCSVControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsCSVControllerTests]/[method:updates_in_upsert_correctly()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setSection → KILLED

165

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpsertStudentUpdatingTheEmail()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setEmail → KILLED

166

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsCSVControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsCSVControllerTests]/[method:updates_in_upsert_correctly()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setStudentId → KILLED

167

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpsertStudentUpdatingTheEmail()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::upsertStudent → KILLED

169

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPostRosterStudent_emailSanitized()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setCourse → KILLED

170

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPostRosterStudent_withUmail()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setEmail → KILLED

171

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPostRosterStudent_emailSanitized()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setRosterStatus → KILLED

174

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.CanvasControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.CanvasControllerTests]/[method:testUploadRosterFromCanvas_setsPENDINGStatusWhenNoInstallationId()]
negated conditional → KILLED

175

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.CanvasControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.CanvasControllerTests]/[method:testUploadRosterFromCanvas_setsJOINCOURSEStatusWhenInstallationIdPresent()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setOrgStatus → KILLED

177

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.CanvasControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.CanvasControllerTests]/[method:testUploadRosterFromCanvas_setsPENDINGStatusWhenNoInstallationId()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setOrgStatus → KILLED

179

1.1
Location : upsertStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPostRosterStudent_withSection()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::upsertStudent → KILLED

191

1.1
Location : lambda$updateCourseMembership$0
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:notFound()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$updateCourseMembership$0 → KILLED

192

1.1
Location : updateCourseMembership
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:just_no_org_name()]
negated conditional → KILLED

2.2
Location : updateCourseMembership
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:not_registered_org()]
negated conditional → KILLED

202

1.1
Location : updateCourseMembership
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:job_actually_fires()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::updateCourseMembership → KILLED

223

1.1
Location : lambda$joinCourseOnGitHub$0
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testLinkGitHub_notFound()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$joinCourseOnGitHub$0 → KILLED

225

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testJoinCourseOnGitHub_nullUser()]
negated conditional → KILLED

2.2
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testJoinCourseOnGitHub_unauthorized()]
negated conditional → KILLED

229

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:access_denied_on_dropped()]
negated conditional → KILLED

234

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testJoinCourseOnGitHub_alreadyJoined()]
negated conditional → KILLED

235

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testJoinCourseOnGitHub_alreadyJoined()]
negated conditional → KILLED

236

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testJoinCourseOnGitHub_alreadyJoined()]
negated conditional → KILLED

237

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testJoinCourseOnGitHub_alreadyJoined_Owner()]
negated conditional → KILLED

238

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testJoinCourseOnGitHub_alreadyJoined()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::joinCourseOnGitHub → KILLED

242

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:no_fire_on_no_org_name()]
negated conditional → KILLED

243

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:no_fire_on_no_installation_id()]
negated conditional → KILLED

244

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:no_fire_on_no_installation_id()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::joinCourseOnGitHub → KILLED

247

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:test_already_part_is_member()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setGithubId → KILLED

248

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:cant_invite()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setGithubLogin → KILLED

250

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:test_already_part_is_member()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setOrgStatus → KILLED

252

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:cant_invite()]
negated conditional → KILLED

253

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:test_fires_invite()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::joinCourseOnGitHub → KILLED

254

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:cant_invite()]
negated conditional → KILLED

2.2
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:cant_invite()]
negated conditional → KILLED

255

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:test_already_part_is_member()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::joinCourseOnGitHub → KILLED

258

1.1
Location : joinCourseOnGitHub
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:cant_invite()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::joinCourseOnGitHub → KILLED

268

1.1
Location : getAssociatedRosterStudents
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testGetAssociatedRosterStudents()]
replaced return value with Collections.emptyList for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::getAssociatedRosterStudents → KILLED

282

1.1
Location : updateRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpdateRosterStudent_nullFields()]
negated conditional → KILLED

2.2
Location : updateRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpdateRosterStudent_nullStudentId()]
negated conditional → KILLED

3.3
Location : updateRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpdateRosterStudent_nullLastName()]
negated conditional → KILLED

285

1.1
Location : updateRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpdateRosterStudent_emptyFirstName()]
negated conditional → KILLED

286

1.1
Location : updateRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpdateRosterStudent_emptyLastName()]
negated conditional → KILLED

287

1.1
Location : updateRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpdateRosterStudent_emptyStudentId()]
negated conditional → KILLED

294

1.1
Location : lambda$updateRosterStudent$0
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpdateRosterStudent_notFound()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$updateRosterStudent$0 → KILLED

296

1.1
Location : updateRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpdateRosterStudent_duplicateStudentId()]
negated conditional → KILLED

300

1.1
Location : updateRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpdateRosterStudent_duplicateStudentId()]
negated conditional → KILLED

306

1.1
Location : updateRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpdateRosterStudent_success()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setFirstName → KILLED

307

1.1
Location : updateRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpdateRosterStudent_success()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setLastName → KILLED

308

1.1
Location : updateRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpdateRosterStudent_newStudentIdNotExists()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setStudentId → KILLED

310

1.1
Location : updateRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpdateRosterStudent_updatesSectionWhenProvided()]
negated conditional → KILLED

311

1.1
Location : updateRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpdateRosterStudent_updatesSectionWhenProvided()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setSection → KILLED

314

1.1
Location : updateRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testUpdateRosterStudent_success()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::updateRosterStudent → KILLED

327

1.1
Location : lambda$restoreRosterStudent$0
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testRestoreRosterStudent_notFound()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$restoreRosterStudent$0 → KILLED

328

1.1
Location : restoreRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testRestoreRosterStudent_success()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setRosterStatus → KILLED

329

1.1
Location : restoreRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testRestoreRosterStudent_success()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::restoreRosterStudent → KILLED

354

1.1
Location : lambda$deleteRosterStudent$0
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testDeleteRosterStudent_notFound()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$deleteRosterStudent$0 → KILLED

358

1.1
Location : deleteRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testDeleteRosterStudent_success()]
negated conditional → KILLED

359

1.1
Location : deleteRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testDeleteRosterStudent_success()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::deleteRosterStudent → KILLED

361

1.1
Location : deleteRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testDeleteRosterStudent_withGithubLogin_orgRemovalFails()]
negated conditional → KILLED

362

1.1
Location : deleteRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testDeleteRosterStudent_withRemoveFromOrgTrue_success()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::deleteRosterStudent → KILLED

365

1.1
Location : deleteRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testDeleteRosterStudent_withGithubLogin_orgRemovalFails()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::deleteRosterStudent → KILLED

388

1.1
Location : lambda$purgeDroppedRosterStudents$0
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPurgeDropped_courseNotFound()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::lambda$purgeDroppedRosterStudents$0 → KILLED

401

1.1
Location : purgeDroppedRosterStudents
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPurgeDropped_removesFromOrgByDefault_andReportsFailures()]
Changed increment from 1 to -1 → KILLED

402

1.1
Location : purgeDroppedRosterStudents
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPurgeDropped_removesFromOrgByDefault_andReportsFailures()]
negated conditional → KILLED

403

1.1
Location : purgeDroppedRosterStudents
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPurgeDropped_removesFromOrgByDefault_andReportsFailures()]
Changed increment from 1 to -1 → KILLED

404

1.1
Location : purgeDroppedRosterStudents
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPurgeDropped_removesFromOrgByDefault_andReportsFailures()]
negated conditional → KILLED

408

1.1
Location : purgeDroppedRosterStudents
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPurgeDropped_noDroppedStudents()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::purgeDroppedRosterStudents → KILLED

429

1.1
Location : deleteSingleRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testDeleteRosterStudent_withGithubLogin_orgRemovalFails()]
negated conditional → KILLED

430

1.1
Location : deleteSingleRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testDeleteRosterStudent_withGithubLogin_orgRemovalFails()]
negated conditional → KILLED

431

1.1
Location : deleteSingleRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testDeleteRosterStudent_withGithubLogin_noOrgName_success()]
negated conditional → KILLED

432

1.1
Location : deleteSingleRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testDeleteRosterStudent_withGithubLogin_noInstallationId_success()]
negated conditional → KILLED

435

1.1
Location : deleteSingleRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testDeleteRosterStudent_withGithubLogin_orgRemovalFails()]
removed call to edu/ucsb/cs156/frontiers/services/OrganizationMemberService::removeOrganizationMember → KILLED

444

1.1
Location : deleteSingleRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPurgeDropped_removeFromOrgFalse_skipsOrgRemoval_andDetachesTeams()]
negated conditional → KILLED

447

1.1
Location : deleteSingleRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPurgeDropped_removeFromOrgFalse_skipsOrgRemoval_andDetachesTeams()]
removed call to java/util/List::forEach → KILLED

450

1.1
Location : lambda$deleteSingleRosterStudent$0
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testPurgeDropped_removeFromOrgFalse_skipsOrgRemoval_andDetachesTeams()]
removed call to edu/ucsb/cs156/frontiers/entities/TeamMember::setTeam → KILLED

455

1.1
Location : deleteSingleRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testDeleteRosterStudent_withRemoveFromOrgFalse_noGithubLogin_success()]
removed call to edu/ucsb/cs156/frontiers/entities/RosterStudent::setCourse → KILLED

456

1.1
Location : deleteSingleRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testDeleteRosterStudent_success()]
removed call to edu/ucsb/cs156/frontiers/repositories/RosterStudentRepository::delete → KILLED

458

1.1
Location : deleteSingleRosterStudent
Killed by : edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.frontiers.controllers.RosterStudentsControllerTests]/[method:testDeleteRosterStudent_success()]
replaced return value with null for edu/ucsb/cs156/frontiers/controllers/RosterStudentsController::deleteSingleRosterStudent → KILLED

Active mutators

Tests examined


Report generated by PIT 1.30.0 support