MCPcopy Index your code
hub / github.com/SSheldon/rust-dispatch / test_serial_queue

Function test_serial_queue

src/queue.rs:354–362  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

352
353 #[test]
354 fn test_serial_queue() {
355 let q = Queue::create("", QueueAttribute::Serial);
356 let mut num = 0;
357
358 q.exec_sync(|| num = 1);
359 assert_eq!(num, 1);
360
361 assert_eq!(q.exec_sync(|| num), 1);
362 }
363
364 #[test]
365 fn test_sync_owned() {

Callers

nothing calls this directly

Calls 1

exec_syncMethod · 0.80

Tested by

no test coverage detected