Use execute-batch! to populate 1000 rows for testing foldable
This commit is contained in:
parent
7b24e2ff55
commit
90a6476e52
1 changed files with 3 additions and 3 deletions
|
|
@ -298,9 +298,9 @@ VALUES ('Pear', 'green', 49, 47)
|
|||
(deftest folding-test
|
||||
(println "=== folding-test setup for" (:dbtype (db)))
|
||||
(jdbc/execute-one! (ds) ["delete from fruit"])
|
||||
(doseq [n (range 1 1001)]
|
||||
(jdbc/execute-one! (ds) ["insert into fruit(name) values (?)"
|
||||
(str "Fruit-" n)]))
|
||||
(with-open [con (jdbc/get-connection (ds))
|
||||
ps (jdbc/prepare con ["insert into fruit(name) values (?)"])]
|
||||
(prep/execute-batch! ps (mapv #(vector (str "Fruit-" %)) (range 1 1001))))
|
||||
(println "=== folding-test running for" (:dbtype (db)))
|
||||
(testing "foldable result set"
|
||||
(testing "from a Connection"
|
||||
|
|
|
|||
Loading…
Reference in a new issue