mirror of
https://github.com/zed-industries/zed.git
synced 2024-12-24 17:28:40 +00:00
Reduce logging in lsp tests
This commit is contained in:
parent
d84fc3beec
commit
8d6504826c
4 changed files with 11 additions and 7 deletions
4
Cargo.lock
generated
4
Cargo.lock
generated
|
@ -2776,6 +2776,8 @@ version = "0.1.0"
|
|||
dependencies = [
|
||||
"anyhow",
|
||||
"async-pipe",
|
||||
"ctor",
|
||||
"env_logger",
|
||||
"futures",
|
||||
"gpui",
|
||||
"log",
|
||||
|
@ -2784,7 +2786,6 @@ dependencies = [
|
|||
"postage",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"simplelog",
|
||||
"smol",
|
||||
"unindent",
|
||||
"util",
|
||||
|
@ -3523,7 +3524,6 @@ dependencies = [
|
|||
"rpc",
|
||||
"serde",
|
||||
"serde_json",
|
||||
"simplelog",
|
||||
"smol",
|
||||
"sum_tree",
|
||||
"tempdir",
|
||||
|
|
|
@ -27,5 +27,6 @@ smol = "1.2"
|
|||
gpui = { path = "../gpui", features = ["test-support"] }
|
||||
util = { path = "../util", features = ["test-support"] }
|
||||
async-pipe = { git = "https://github.com/routerify/async-pipe-rs", rev = "feeb77e83142a9ff837d0767652ae41bfc5d8e47" }
|
||||
simplelog = "0.9"
|
||||
ctor = "0.1"
|
||||
env_logger = "0.8"
|
||||
unindent = "0.1.7"
|
||||
|
|
|
@ -707,10 +707,16 @@ impl FakeLanguageServer {
|
|||
mod tests {
|
||||
use super::*;
|
||||
use gpui::TestAppContext;
|
||||
use simplelog::SimpleLogger;
|
||||
use unindent::Unindent;
|
||||
use util::test::temp_tree;
|
||||
|
||||
#[ctor::ctor]
|
||||
fn init_logger() {
|
||||
if std::env::var("RUST_LOG").is_ok() {
|
||||
env_logger::init();
|
||||
}
|
||||
}
|
||||
|
||||
#[gpui::test]
|
||||
async fn test_rust_analyzer(cx: TestAppContext) {
|
||||
let lib_source = r#"
|
||||
|
@ -771,8 +777,6 @@ mod tests {
|
|||
|
||||
#[gpui::test]
|
||||
async fn test_fake(cx: TestAppContext) {
|
||||
SimpleLogger::init(log::LevelFilter::Info, Default::default()).unwrap();
|
||||
|
||||
let (server, mut fake) = LanguageServer::fake(&cx).await;
|
||||
|
||||
let (message_tx, message_rx) = channel::unbounded();
|
||||
|
|
|
@ -49,6 +49,5 @@ lsp = { path = "../lsp", features = ["test-support"] }
|
|||
util = { path = "../util", features = ["test-support"] }
|
||||
rpc = { path = "../rpc", features = ["test-support"] }
|
||||
rand = "0.8.3"
|
||||
simplelog = "0.9"
|
||||
tempdir = { version = "0.3.7" }
|
||||
unindent = "0.1.7"
|
||||
|
|
Loading…
Reference in a new issue