]> gitweb.factorcode.org Git - factor.git/commitdiff
Fix unit test for when auto-use isnt on and test the other constructor error condition
authorDoug Coleman <doug.coleman@gmail.com>
Sat, 24 Apr 2010 04:30:51 +0000 (23:30 -0500)
committerDoug Coleman <doug.coleman@gmail.com>
Sat, 24 Apr 2010 04:30:51 +0000 (23:30 -0500)
extra/constructors/constructors-tests.factor

index fef3150f6e1a05df809422fa40db8bfcaf1075f0..0ad83a6c5fa4a9c57bcab9a9f34617367b44afec 100644 (file)
@@ -43,7 +43,17 @@ CONSTRUCTOR: ct4 ( a b c d -- obj )
 [ 4 ] [ 0 0 0 0 <ct4> a>> ] unit-test
 
 [
-    """IN: constructors.tests
+    """USE: constructors
+IN: constructors.tests
+TUPLE: foo a b ;
+CONSTRUCTOR: foo ( a a -- obj ) ;""" eval( -- )
+] [
+    error>> repeated-constructor-parameters?
+] must-fail-with
+
+[
+    """USE: constructors
+IN: constructors.tests
 TUPLE: foo a b ;
 CONSTRUCTOR: foo ( a c -- obj ) ;""" eval( -- )
 ] [