]> gitweb.factorcode.org Git - factor.git/blobdiff - basis/listener/listener-tests.factor
Set up listener's manifest so that words defined in "scratchpad" take precedence...
[factor.git] / basis / listener / listener-tests.factor
index 907c45360d9ca868c8744e5371aa1e2ad4c965a7..4a97996637831e1efb0efde4f7ff1d33e277b41a 100644 (file)
@@ -1,6 +1,6 @@
 USING: io io.streams.string io.streams.duplex listener
 tools.test parser math namespaces continuations vocabs kernel
-compiler.units eval vocabs.parser ;
+compiler.units eval vocabs.parser words definitions ;
 IN: listener.tests
 
 SYNTAX: hello "Hi" print ;
@@ -52,3 +52,16 @@ SYNTAX: hello "Hi" print ;
         drop
     ] unit-test
 ] with-file-vocabs
+
+[ "call" "scratchpad" create drop ] with-compilation-unit
+
+[
+    [ t ]
+    [
+        "call" "scratchpad" lookup-word
+        [ "call" search ] with-interactive-vocabs
+        eq?
+    ] unit-test 
+] with-file-vocabs
+
+[ "call" "scratchpad" lookup-word forget ] with-compilation-unit