]> gitweb.factorcode.org Git - factor.git/commitdiff
tools.test/help.lint: use vocab-roots instead of resource: head?
authorJohn Benediktsson <mrjbq7@gmail.com>
Sun, 22 Nov 2020 17:24:35 +0000 (09:24 -0800)
committerJohn Benediktsson <mrjbq7@gmail.com>
Sun, 22 Nov 2020 17:24:35 +0000 (09:24 -0800)
basis/help/lint/lint.factor
basis/tools/test/test.factor

index 749a76aeec53ed6f2f3f326fe066a374a28a3013..da4c9547ad6bb204cc7de0476f7a819bc2f9b072 100644 (file)
@@ -104,7 +104,8 @@ PRIVATE>
 : test-lint-main ( -- )
     command-line get dup first "--only" = [
         V{ } clone swap rest [
-            dup "resource:" head? [ "" vocabs-to-load append! ] [ suffix! ] if
+            dup vocab-roots get member?
+            [ "" vocabs-to-load append! ] [ suffix! ] if
         ] each [ require-all ] [ help-lint-vocabs ] bi
     ] [
         [ [ load ] [ help-lint ] bi ] each
index cc813f596b4a7ccc1ed25a1506d77e9fc9af1750..e8c0707e7fc54bc2117fc2ce260aaa10b1655c35 100644 (file)
@@ -222,15 +222,15 @@ M: test-failure error. ( error -- )
 : :test-failures ( -- ) test-failures get errors. ;
 
 : test ( prefix -- )
-    loaded-child-vocab-names test-vocabs ;
+    loaded-child-vocab-names [ don't-test? ] reject test-vocabs ;
 
-: test-all ( -- )
-    loaded-vocab-names [ don't-test? ] reject test-vocabs ;
+: test-all ( -- ) "" test ;
 
 : test-main ( -- )
     command-line get dup first "--only" = [
         V{ } clone swap rest [
-            dup "resource:" head? [ "" vocabs-to-load append! ] [ suffix! ] if
+            dup vocab-roots get member?
+            [ "" vocabs-to-load append! ] [ suffix! ] if
         ] each [ require-all ] [ test-vocabs ] bi
     ] [
         [ [ load ] [ test ] bi ] each