CurrentUser.java

1
package edu.ucsb.cs156.gauchoride.models;
2
3
import lombok.Data;
4
import lombok.AllArgsConstructor;
5
import lombok.NoArgsConstructor;
6
import lombok.Builder;
7
import lombok.AccessLevel;
8
9
10
import org.springframework.security.core.GrantedAuthority;
11
12
import edu.ucsb.cs156.gauchoride.entities.User;
13
14
import java.util.Collection;
15
16
@Data
17
@AllArgsConstructor
18
@NoArgsConstructor(access = AccessLevel.PROTECTED)
19
@Builder
20
public class CurrentUser {
21
  private User user;
22
  private Collection<? extends GrantedAuthority> roles;
23
  public Long getId() {
24 1 1. getId : replaced Long return value with 0L for edu/ucsb/cs156/gauchoride/models/CurrentUser::getId → KILLED
    return user.getId();
25
  }
26
}

Mutations

24

1.1
Location : getId
Killed by : edu.ucsb.cs156.gauchoride.models.CurrentUserTests.[engine:junit-jupiter]/[class:edu.ucsb.cs156.gauchoride.models.CurrentUserTests]/[method:testGetIdReturnsCorrectId()]
replaced Long return value with 0L for edu/ucsb/cs156/gauchoride/models/CurrentUser::getId → KILLED

Active mutators

Tests examined


Report generated by PIT 1.7.3