diff options
author | Morgan Astra <givengravity@gmail.com> | 2018-11-15 00:04:50 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-11-15 00:04:50 -0800 |
commit | f81ef6b889807dd0edbd3249e1069224ab87782a (patch) | |
tree | 99c63b25061e7c6b134fda7ba577a993d183a1a1 /test/pronouns/util_test.clj | |
parent | a1f10d3b04b65030f660d41f92be2bf34c230222 (diff) | |
parent | 4e6941768364d3337bff6ac2e2be5c8db5df197b (diff) |
Merge pull request #91 from witch-house/develop
Merge develop into master... for the last time!
Diffstat (limited to 'test/pronouns/util_test.clj')
-rw-r--r-- | test/pronouns/util_test.clj | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/test/pronouns/util_test.clj b/test/pronouns/util_test.clj new file mode 100644 index 0000000..3aecc2a --- /dev/null +++ b/test/pronouns/util_test.clj @@ -0,0 +1,32 @@ +(ns pronouns.util-test + (:require [pronouns.util :as util] + [clojure.test :refer [deftest testing is are]])) + +(def test-table [["ze" "hir" "hir" "hirs" "hirself"] + ["ze" "zir" "zir" "zirs" "zirself"] + ["she" "her" "her" "hers" "herself"] + ["he" "him" "his" "his" "himself"] + ["they" "them" "their" "theirs" "themselves"] + ["they" "them" "their" "theirs" "themself"]]) + +(deftest table-filters + (testing "table-front-filter" + (are [arg return] (= (util/table-front-filter arg test-table) return) + ["she"] [["she" "her" "her" "hers" "herself"]] + ["ze"] [["ze" "hir" "hir" "hirs" "hirself"] + ["ze" "zir" "zir" "zirs" "zirself"]] + ["ze" "zir"] [["ze" "zir" "zir" "zirs" "zirself"]])) + + (testing "table-end-filter" + (are [arg return] (= (util/table-end-filter arg test-table) return) + ["themself"] [["they" "them" "their" "theirs" "themself"]] + ["themselves"] [["they" "them" "their" "theirs" "themselves"]]))) + +(deftest table-lookup + (are [arg return] (= (util/table-lookup arg test-table) return) + ["she"] ["she" "her" "her" "hers" "herself"] + ["ze"] ["ze" "hir" "hir" "hirs" "hirself"] + ["ze" "zir"] ["ze" "zir" "zir" "zirs" "zirself"] + ["they"] ["they" "them" "their" "theirs" "themselves"] + ["they" "..." "themself"] ["they" "them" "their" "theirs" "themself"])) + |