From fa621f80fabe2c9d36fb2af57785e184fb331939 Mon Sep 17 00:00:00 2001 From: Edwin Cheng Date: Fri, 27 Mar 2020 05:08:26 +0800 Subject: [PATCH] Fix test --- Cargo.lock | 1 - crates/ra_proc_macro/Cargo.toml | 5 ++--- crates/ra_proc_macro/src/rpc.rs | 2 +- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 7887bc2176b..f9265af4386 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1079,7 +1079,6 @@ dependencies = [ "log", "ra_tt", "serde", - "serde_derive", "serde_json", ] diff --git a/crates/ra_proc_macro/Cargo.toml b/crates/ra_proc_macro/Cargo.toml index 7b4ff993f37..f4a1b6d9e9e 100644 --- a/crates/ra_proc_macro/Cargo.toml +++ b/crates/ra_proc_macro/Cargo.toml @@ -10,8 +10,7 @@ doctest = false [dependencies] ra_tt = { path = "../ra_tt" } -serde_derive = "1.0.104" -serde = "1.0.104" -serde_json = "1.0.48" +serde = { version = "1.0", features = ["derive"] } +serde_json = "1.0" log = "0.4.8" crossbeam-channel = "0.4.0" diff --git a/crates/ra_proc_macro/src/rpc.rs b/crates/ra_proc_macro/src/rpc.rs index e7eaf7c15b2..f88d91f782c 100644 --- a/crates/ra_proc_macro/src/rpc.rs +++ b/crates/ra_proc_macro/src/rpc.rs @@ -252,7 +252,7 @@ fn test_proc_macro_rpc_works() { assert_eq!(task.macro_body, back.macro_body); let result = ExpansionResult { expansion: tt.clone() }; - let json = serde_json::to_string(&task).unwrap(); + let json = serde_json::to_string(&result).unwrap(); let back: ExpansionResult = serde_json::from_str(&json).unwrap(); assert_eq!(result, back);