From ec0871ef6910d4ec61bd917adc20a4ef91d966a8 Mon Sep 17 00:00:00 2001 From: Simon Cruanes Date: Wed, 4 Sep 2024 16:00:25 -0400 Subject: [PATCH] wip: tests --- test/picos/basic_test.ml | 11 +++++++++++ test/picos/dune | 3 +++ 2 files changed, 14 insertions(+) create mode 100644 test/picos/basic_test.ml create mode 100644 test/picos/dune diff --git a/test/picos/basic_test.ml b/test/picos/basic_test.ml new file mode 100644 index 0000000..f750064 --- /dev/null +++ b/test/picos/basic_test.ml @@ -0,0 +1,11 @@ +let () = + Picos_mux_fifo.run @@ fun () -> + match + Ezcurl_picos.get + ~url: + "https://archive.softwareheritage.org/api/1/content/sha1_git:7bdf38d4468c114206c9b6ebd9cf1176e085d346/" + () + with + | Error (code, msg) -> + Format.eprintf "curl error: code `%s` (%s)@." (Curl.strerror code) msg + | Ok _response -> Format.printf "OK@." diff --git a/test/picos/dune b/test/picos/dune new file mode 100644 index 0000000..bb95b3b --- /dev/null +++ b/test/picos/dune @@ -0,0 +1,3 @@ +(test + (name basic_test) + (libraries ezcurl_picos picos_mux.fifo))