mirror of
https://chromium.googlesource.com/crosvm/crosvm
synced 2025-02-11 04:26:38 +00:00
cros_async: event - fix poll unit test
Make the unit test explicitly run the poll or uring back end. This will fix running the test if the host doesn't support uring. Change-Id: I3b5e585c0b5ee442ef41c77c21ae6742c18a3ff4 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/2545126 Tested-by: kokoro <noreply+kokoro@google.com> Commit-Queue: Dylan Reid <dgreid@chromium.org> Reviewed-by: Chirantan Ekbote <chirantan@chromium.org>
This commit is contained in:
parent
d32098de9a
commit
385c320525
1 changed files with 2 additions and 2 deletions
|
@ -78,14 +78,14 @@ mod tests {
|
|||
eventfd.write(0xaa).unwrap();
|
||||
let fut = go(EventAsync::new_uring(eventfd).unwrap());
|
||||
pin_mut!(fut);
|
||||
let val = crate::run_executor(crate::RunOne::new(fut)).unwrap();
|
||||
let val = crate::run_one_uring(fut).unwrap();
|
||||
assert_eq!(val, 0xaa);
|
||||
|
||||
let eventfd = EventFd::new().unwrap();
|
||||
eventfd.write(0xaa).unwrap();
|
||||
let fut = go(EventAsync::new_poll(eventfd).unwrap());
|
||||
pin_mut!(fut);
|
||||
let val = crate::run_executor(crate::RunOne::new(fut)).unwrap();
|
||||
let val = crate::run_one_poll(fut).unwrap();
|
||||
assert_eq!(val, 0xaa);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue