Skip to content

Commit

Permalink
fix mstatus tests
Browse files Browse the repository at this point in the history
  • Loading branch information
romancardenas committed May 18, 2024
1 parent c4927e1 commit 794b7e0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions riscv/src/register/mstatus.rs
Original file line number Diff line number Diff line change
Expand Up @@ -602,11 +602,11 @@ mod test {
#[test]
fn test_mpp() {
let mut mstatus = Mstatus { bits: 0 };
mstatus = mstatus.set_mpp(MPP::User);
mstatus.set_mpp(MPP::User);
assert_eq!(mstatus.mpp(), MPP::User);
mstatus = mstatus.set_mpp(MPP::Machine);
mstatus.set_mpp(MPP::Machine);
assert_eq!(mstatus.mpp(), MPP::Machine);
mstatus = mstatus.set_mpp(MPP::Supervisor);
mstatus.set_mpp(MPP::Supervisor);
assert_eq!(mstatus.mpp(), MPP::Supervisor);
}
}

0 comments on commit 794b7e0

Please sign in to comment.