(*--------------------------------------------------------------------------- Copyright (c) 2025 Anil Madhavapeddy . All rights reserved. SPDX-License-Identifier: ISC ---------------------------------------------------------------------------*) (** Test using One module directly without connection pooling *) let () = Vlog.setup_test ~level:Logs.Debug (); Crypto_rng_unix.use_default (); Eio_main.run @@ fun env -> Eio.Switch.run @@ fun sw -> try let response = Requests.One.get ~sw ~clock:env#clock ~net:env#net "https://opam.ocaml.org" in Fmt.pr "Status: %d\n%!" (Requests.Response.status_code response) with e -> Fmt.pr "Exception: %s\n%!" (Printexc.to_string e); Printexc.print_backtrace stdout