aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorHarald Eilertsen <haraldei@anduin.net>2019-03-04 17:22:15 +0100
committerHarald Eilertsen <haraldei@anduin.net>2019-03-04 17:22:15 +0100
commit14cf4b8fdd69b31c8030b6530bbe07fd1df5b25a (patch)
treeb38dd2e7fb3dcb0186c478b5dd2b3b22733eb273 /tests
parent1f89095fc559c0686aa7e79340c29c7f5a04658b (diff)
downloadramaskrik-social-14cf4b8fdd69b31c8030b6530bbe07fd1df5b25a.tar.gz
ramaskrik-social-14cf4b8fdd69b31c8030b6530bbe07fd1df5b25a.tar.bz2
ramaskrik-social-14cf4b8fdd69b31c8030b6530bbe07fd1df5b25a.zip
Use rocket_contrib's JsonValue as return type.
Diffstat (limited to 'tests')
-rw-r--r--tests/room_tests.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/room_tests.rs b/tests/room_tests.rs
index 7415fd5..c91519d 100644
--- a/tests/room_tests.rs
+++ b/tests/room_tests.rs
@@ -17,11 +17,13 @@
*/
use ramaskrik;
+use rocket::http::ContentType;
#[test]
fn getting_rooms_from_api() {
let server = ramaskrik::build_rocket().unwrap();
let client = rocket::local::Client::new(server).unwrap();
let mut response = client.get("/rooms").dispatch();
+ assert_eq!(response.content_type(), Some(ContentType::JSON));
assert_eq!(response.body_string(), Some("[]".into()));
}