Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
reqwest_client: Remove example (#37410)
Marshall Bowers7ea7f4e76765
diff --git a/Cargo.lock b/Cargo.lockindex 42e343e0629..50e57005fd1 100644--- a/Cargo.lock+++ b/Cargo.lock@@ -13748,7 +13748,6 @@ dependencies = ["regex","reqwest 0.12.15 (git+https://github.com/zed-industries/reqwest.git?rev=951c770a32f1998d6e999cef3e59e0013e6c4415)","serde",- "smol","tokio","workspace-hack",]diff --git a/crates/reqwest_client/Cargo.toml b/crates/reqwest_client/Cargo.tomlindex 20b5177a733..68a354c13b9 100644--- a/crates/reqwest_client/Cargo.toml+++ b/crates/reqwest_client/Cargo.toml@@ -15,10 +15,6 @@ test-support = []path = "src/reqwest_client.rs"doctest = true-[[example]]-name = "client"-path = "examples/client.rs"-[dependencies]anyhow.workspace = truebytes.workspace = true@@ -26,7 +22,6 @@ futures.workspace = truehttp_client.workspace = truehttp_client_tls.workspace = trueserde.workspace = true-smol.workspace = truelog.workspace = truetokio = { workspace = true, features = ["rt", "rt-multi-thread"] }regex.workspace = truediff --git a/crates/reqwest_client/examples/client.rs b/crates/reqwest_client/examples/client.rsdeleted file mode 100644index 71af8d72cb3..00000000000--- a/crates/reqwest_client/examples/client.rs+++ /dev/null@@ -1,41 +0,0 @@-use std::time::Instant;--use futures::AsyncReadExt as _;-use futures::stream::FuturesUnordered;-use http_client::AsyncBody;-use http_client::HttpClient;-use reqwest_client::ReqwestClient;-use smol::stream::StreamExt;--fn main() {- let app = gpui::Application::new();- app.run(|cx| {- cx.spawn(async move |cx| {- let client = ReqwestClient::new();- let start = Instant::now();- let requests = [- client.get("https://www.google.com/", AsyncBody::empty(), true),- client.get("https://zed.dev/", AsyncBody::empty(), true),- client.get("https://docs.rs/", AsyncBody::empty(), true),- ];- let mut requests = requests.into_iter().collect::<FuturesUnordered<_>>();- while let Some(response) = requests.next().await {- let mut body = String::new();- response- .unwrap()- .into_body()- .read_to_string(&mut body)- .await- .unwrap();- println!("{}", &body.len());- }- println!("{:?}", start.elapsed());-- cx.update(|cx| {- cx.quit();- })- .ok();- })- .detach();- })-}