From cfedd5c1afad4a14f29bb7c19368cd7f4f9b9c1b Mon Sep 17 00:00:00 2001 From: Josha von Gizycki Date: Mon, 14 Jan 2019 12:23:34 +0100 Subject: [PATCH] add test for size option in mselect, inc clojure version --- project.clj | 2 +- test/formulare/theme_test.clj | 9 ++++++++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/project.clj b/project.clj index c8a3f56..6b7942b 100644 --- a/project.clj +++ b/project.clj @@ -4,7 +4,7 @@ :scm {:name "git" :url "https://gitea.heevyis.ninja/josha/formulare.git"} :license {:name "GPL-3.0" :url "https://opensource.org/licenses/GPL-3.0"} - :dependencies [[org.clojure/clojure "1.9.0"] + :dependencies [[org.clojure/clojure "1.10.0"] [hiccup "1.0.5"] [ring/ring-anti-forgery "1.3.0"]] :deploy-repositories [["clojars" {:sign-releases false diff --git a/test/formulare/theme_test.clj b/test/formulare/theme_test.clj index 3dc8117..944db51 100644 --- a/test/formulare/theme_test.clj +++ b/test/formulare/theme_test.clj @@ -73,7 +73,14 @@ (-> (render-widgets {:fields {:foo {:widget :mselect}}} {} {}) (nth 2) - (nth 2)))))) + (nth 2))))) + (testing "size attribute is used" + (is (= 20 (-> (render-widgets {:fields {:foo {:widget :mselect :size 20}}} + {} {}) + (nth 2) + (nth 2) + second + :size))))) (deftest hidden-is-overridable (binding [*hidden-widget-theme* (fn [& _] \a)]