Skip to content

Commit fb53cca

Browse files
committed
Use graphql's value macro instead of local rewrite
1 parent dd725e6 commit fb53cca

File tree

1 file changed

+3
-9
lines changed

1 file changed

+3
-9
lines changed

src/graphql/mod.rs

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -624,13 +624,14 @@ mod tests {
624624
use std::error::Error;
625625
use std::fs;
626626

627-
use async_graphql::{EmptySubscription, InputType as _, Request, Schema, SchemaBuilder, Value};
627+
use async_graphql::{
628+
value, EmptySubscription, InputType as _, Request, Schema, SchemaBuilder, Value,
629+
};
628630
use axum::http::HeaderValue;
629631
use axum_extra::headers::authorization::{Bearer, Credentials};
630632
use axum_extra::headers::Authorization;
631633
use httpmock::MockServer;
632634
use rstest::{fixture, rstest};
633-
use serde_json::json;
634635
use tempfile::TempDir;
635636

636637
use super::auth::PolicyCheck;
@@ -673,13 +674,6 @@ mod tests {
673674
}
674675
}
675676

676-
/// Helper for creating graphql values from literals
677-
macro_rules! value {
678-
($tree:tt) => {
679-
Value::from_json(json!($tree)).unwrap()
680-
};
681-
}
682-
683677
#[fixture]
684678
async fn db() -> SqliteScanPathService {
685679
let db = SqliteScanPathService::memory().await;

0 commit comments

Comments
 (0)