Browse Source

Merge pull request #100 from Freax13/amlcontext-test-send-sync

Add test to verify that AmlContext implements Send and Sync
Isaac Woods 4 năm trước cách đây
mục cha
commit
d8ce7f4375
1 tập tin đã thay đổi với 12 bổ sung0 xóa
  1. 12 0
      aml/src/lib.rs

+ 12 - 0
aml/src/lib.rs

@@ -791,3 +791,15 @@ pub enum AmlError {
     FieldInvalidAccessSize,
     TypeCannotBeCompared(AmlType),
 }
+
+#[cfg(test)]
+mod tests {
+    use super::*;
+
+    #[test]
+    fn test_send_sync() {
+        // verify that AmlContext implements Send and Sync
+        fn test_send_sync<T: Send + Sync>() {}
+        test_send_sync::<AmlContext>();
+    }
+}