Skip to content

Commit

Permalink
aml: Fix tests not building with IndexField
Browse files Browse the repository at this point in the history
  • Loading branch information
alnyan committed Oct 3, 2023
1 parent 6c7f593 commit e65ccf4
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions aml/src/test_utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,18 @@ pub(crate) fn crudely_cmp_values(a: &AmlValue, b: &AmlValue) -> bool {
}
_ => false,
},
AmlValue::IndexField { index, data, flags, offset, length } => match b {
AmlValue::IndexField {
index: b_index,
data: b_data,
flags: b_flags,
offset: b_offset,
length: b_length,
} => {
index == b_index && data == b_data && flags == b_flags && offset == b_offset && length == b_length
}
_ => false,
},
AmlValue::Device => match b {
AmlValue::Device => true,
_ => false,
Expand Down

0 comments on commit e65ccf4

Please sign in to comment.