summaryrefslogtreecommitdiff
path: root/test/schema.ml
diff options
context:
space:
mode:
authorSébastien Dailly <sebastien@dailly.me>2026-11-20 12:35:08 +0100
committerSébastien Dailly <sebastien@dailly.me>2026-11-20 12:35:08 +0100
commitc4ca180fd7c2085e3ce3f8e32aa0c2cb724f4c53 (patch)
treeeb91601a04f3256e1732a72d3ebe8e1fa5d7a616 /test/schema.ml
parentfb75994d097cb1d6a1a0ea871c2d2213aa4e3c31 (diff)
Reviewed tests
Diffstat (limited to 'test/schema.ml')
-rw-r--r--test/schema.ml7
1 files changed, 3 insertions, 4 deletions
diff --git a/test/schema.ml b/test/schema.ml
index 3b52812..5fcd406 100644
--- a/test/schema.ml
+++ b/test/schema.ml
@@ -25,8 +25,7 @@ let get_schema : Caqti_lwt.connection -> string -> string Lwt.t =
let exec : string list -> t =
fun tables ->
- let stdin = In_channel.input_all stdin in
+ let stdin = Common.read_stdin () in
let+ configuration = Configuration.Read_conf.read_string_conf stdin in
- Lwt_main.run
- (let* db = Common.connect configuration in
- Lwt_list.map_s (get_schema db) (List.rev tables))
+ Common.with_db configuration (fun db ->
+ Lwt_list.map_s (get_schema db) (List.rev tables))