From 07072396b438916b770def6750d2f1f62c6bfa53 Mon Sep 17 00:00:00 2001 From: Colin Jones Date: Tue, 26 Oct 2010 23:45:19 -0500 Subject: [PATCH] Add one more subtask-help test. --- test/test_help.clj | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/test/test_help.clj b/test/test_help.clj index 3c253e95..df257f51 100644 --- a/test/test_help.clj +++ b/test/test_help.clj @@ -3,6 +3,7 @@ [clojure.test])) (def formatted-docstring @#'leiningen.help/formatted-docstring) +(def get-subtasks-and-docstrings-for @#'leiningen.help/get-subtasks-and-docstrings-for) (def formatted-help @#'leiningen.help/formatted-help) (def resolve-task @#'leiningen.help/resolve-task) @@ -19,7 +20,9 @@ (is (= "This is an AWESOME command For real!" - (formatted-docstring "install" "This is an\n AWESOME command\nFor real!" 5)))) + (formatted-docstring + "install" + "This is an\n AWESOME command\nFor real!" 5)))) (deftest test-formatted-help (is (= "install This is an @@ -27,3 +30,8 @@ For real!" (formatted-help "install" "This is an\nAWESOME command\nFor real!" 15)))) +(deftest test-get-subtasks + (let [m (get-subtasks-and-docstrings-for (second (resolve-task "plugin")))] + (is (= ["install" "uninstall"] + (sort (keys m)))))) +