]> gitweb.factorcode.org Git - factor.git/commitdiff
cocoa: clean up tests
authorSlava Pestov <slava@factorcode.org>
Mon, 29 Aug 2011 05:20:39 +0000 (22:20 -0700)
committerSlava Pestov <slava@factorcode.org>
Mon, 29 Aug 2011 05:20:39 +0000 (22:20 -0700)
basis/cocoa/cocoa-tests.factor

index fee8c60c216e441e12531ac5c07702d0efaee376..a2a0b533c3fec8bcf93d2c1a69c72584b6d111f7 100644 (file)
@@ -16,7 +16,7 @@ CLASS: Foo < NSObject
     dup 1.0 2.0 101.0 102.0 <CGRect> -> foo:
     -> release ;
 
-test-foo
+[ ] [ test-foo ] unit-test
 
 [ 1.0 ] [ "x" get CGRect-x ] unit-test
 [ 2.0 ] [ "x" get CGRect-y ] unit-test
@@ -28,11 +28,13 @@ CLASS: Bar < NSObject
     METHOD: NSRect bar [ test-foo "x" get ]
 ]
 
-Bar [
-    -> alloc -> init
-    dup -> bar "x" set
-    -> release
-] compile-call
+[ ] [
+    Bar [
+        -> alloc -> init
+        dup -> bar "x" set
+        -> release
+    ] compile-call
+] unit-test
 
 [ 1.0 ] [ "x" get CGRect-x ] unit-test
 [ 2.0 ] [ "x" get CGRect-y ] unit-test