Tweak http mod visibility.

This commit is contained in:
jcamiel 2023-08-10 14:25:53 +02:00
parent a454a81cdd
commit 17ae56d6db
No known key found for this signature in database
GPG Key ID: 07FF11CFD55356CC
5 changed files with 10 additions and 17 deletions

View File

@ -26,7 +26,7 @@ use std::time::Duration;
use std::{env, io};
use clap::ArgMatches;
use hurl::libcurl_version_info;
use hurl::http;
use hurl::util::logger::{LoggerOptions, LoggerOptionsBuilder, Verbosity};
use hurl::util::path::ContextDir;
use hurl_core::ast::{Entry, Retry};
@ -110,7 +110,7 @@ impl From<ErrorFormat> for hurl::util::logger::ErrorFormat {
}
fn get_version() -> String {
let libcurl_version = libcurl_version_info();
let libcurl_version = http::libcurl_version_info();
format!(
"{} {}\nFeatures (libcurl): {}\nFeatures (built-in): brotli",
clap::crate_version!(),

View File

@ -17,14 +17,14 @@
*/
pub use self::call::Call;
pub use self::certificate::Certificate;
pub use self::client::Client;
pub(crate) use self::client::Client;
pub use self::cookie::{CookieAttribute, ResponseCookie};
pub use self::core::{Cookie, Param, RequestCookie};
pub use self::error::HttpError;
pub(crate) use self::core::{Cookie, Param, RequestCookie};
pub(crate) use self::error::HttpError;
pub use self::header::Header;
pub use self::options::{ClientOptions, Verbosity};
pub(crate) use self::options::{ClientOptions, Verbosity};
pub use self::request::Request;
pub use self::request_spec::{Body, FileParam, Method, MultipartParam, RequestSpec};
pub(crate) use self::request_spec::{Body, FileParam, Method, MultipartParam, RequestSpec};
pub use self::response::{Response, Version};
#[cfg(test)]
pub use self::tests::*;

View File

@ -40,11 +40,10 @@
//!
//! This crate works on Windows, macOS and Linux.
mod html;
mod http;
pub mod http;
mod json;
mod jsonpath;
pub mod output;
pub mod report;
pub mod runner;
pub mod util;
pub use http::libcurl_version_info;

View File

@ -23,11 +23,6 @@ pub use self::hurl_file::run;
pub use self::runner_options::{RunnerOptions, RunnerOptionsBuilder};
pub use self::value::Value;
// We only expose specific structs from the module `http`.
// We don't want to expose the whole internal HTTP client, but needs those structs as
// they're exposed through `EntryResult`.
pub use crate::http::{Call, Certificate, Cookie, Header, Request, Response, Timings, Version};
mod assert;
mod body;
mod capture;

View File

@ -15,10 +15,9 @@
* limitations under the License.
*
*/
use hurl::http::{Call, Request, Response, Version};
use hurl::runner;
use hurl::runner::{
Call, EntryResult, HurlResult, Request, Response, RunnerOptionsBuilder, Version,
};
use hurl::runner::{EntryResult, HurlResult, RunnerOptionsBuilder};
use hurl::util::logger::LoggerOptionsBuilder;
use hurl::util::path::ContextDir;
use hurl_core::ast::Retry;