]> gitweb.factorcode.org Git - factor.git/blobdiff - basis/concurrency/exchangers/exchangers-tests.factor
core, basis, extra: Remove DOS line endings from files.
[factor.git] / basis / concurrency / exchangers / exchangers-tests.factor
index c411aaea92254edf4974a1fcbf5f18e3f60e052a..8360d1ffe1cefc068d8c36e4201a954152a02816 100644 (file)
@@ -1,29 +1,29 @@
-USING: tools.test concurrency.exchangers\r
-concurrency.count-downs concurrency.promises locals kernel\r
-threads ;\r
-FROM: sequences => 3append ;\r
-IN: concurrency.exchangers.tests\r
-\r
-:: exchanger-test ( -- string )\r
-    <exchanger> :> ex\r
-    2 <count-down> :> c\r
-    f :> v1!\r
-    f :> v2!\r
-    <promise> :> pr\r
-\r
-    [\r
-        c await\r
-        v1 ", " v2 3append pr fulfill\r
-    ] "Awaiter" spawn drop\r
-\r
-    [\r
-        "Goodbye world" ex exchange v1! c count-down\r
-    ] "Exchanger 1" spawn drop\r
-\r
-    [\r
-        "Hello world" ex exchange v2! c count-down\r
-    ] "Exchanger 2" spawn drop\r
-\r
-    pr ?promise ;\r
-\r
-[ "Hello world, Goodbye world" ] [ exchanger-test ] unit-test\r
+USING: tools.test concurrency.exchangers
+concurrency.count-downs concurrency.promises locals kernel
+threads ;
+FROM: sequences => 3append ;
+IN: concurrency.exchangers.tests
+
+:: exchanger-test ( -- string )
+    <exchanger> :> ex
+    2 <count-down> :> c
+    f :> v1!
+    f :> v2!
+    <promise> :> pr
+
+    [
+        c await
+        v1 ", " v2 3append pr fulfill
+    ] "Awaiter" spawn drop
+
+    [
+        "Goodbye world" ex exchange v1! c count-down
+    ] "Exchanger 1" spawn drop
+
+    [
+        "Hello world" ex exchange v2! c count-down
+    ] "Exchanger 2" spawn drop
+
+    pr ?promise ;
+
+[ "Hello world, Goodbye world" ] [ exchanger-test ] unit-test