]> gitweb.factorcode.org Git - factor.git/blobdiff - basis/concurrency/mailboxes/mailboxes-tests.factor
Delete empty unit tests files, remove 1- and 1+, reorder IN: lines in a lot of places...
[factor.git] / basis / concurrency / mailboxes / mailboxes-tests.factor
index 64971eeb77c95f7b45322d4987efd1bd4038a9d2..56d579d6c71cd987a10ebb8ccd22f7fb77ef7c4a 100644 (file)
@@ -1,7 +1,7 @@
-IN: concurrency.mailboxes.tests\r
-USING: concurrency.mailboxes concurrency.count-downs vectors\r
-sequences threads tools.test math kernel strings namespaces\r
+USING: concurrency.mailboxes concurrency.count-downs concurrency.conditions\r
+vectors sequences threads tools.test math kernel strings namespaces\r
 continuations calendar destructors ;\r
+IN: concurrency.mailboxes.tests\r
 \r
 { 1 1 } [ [ integer? ] mailbox-get? ] must-infer-as\r
 \r
@@ -75,3 +75,15 @@ continuations calendar destructors ;
 [ ] [ "d" get 5 seconds await-timeout ] unit-test\r
 \r
 [ ] [ "m" get dispose ] unit-test\r
+\r
+[ { "foo" "bar" } ] [\r
+    <mailbox>\r
+    "foo" over mailbox-put\r
+    "bar" over mailbox-put\r
+    mailbox-get-all\r
+] unit-test\r
+\r
+[\r
+    <mailbox> 1 seconds mailbox-get-timeout\r
+] [ wait-timeout? ] must-fail-with\r
+    \r