From 983e021d5b0fc6b6de130ec558c945f4c4b03310 Mon Sep 17 00:00:00 2001 From: Travis Cross Date: Sun, 26 Jan 2020 00:18:35 +0000 Subject: [PATCH] Fix warning when building site tests (#936) For the site integration tests, we have a file of common code which is used by multiple files in `tests/`. However, not all functions in this file are used by all files in `tests/`. As Cargo compiles each `tests/*.rs` file as a separate crate, this means that some of these crates end up with unused code. Rust notices this and prints a warning. Let's tell Rust that we don't care about dead code in this file so that the warning is not printed. --- components/site/tests/common.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/components/site/tests/common.rs b/components/site/tests/common.rs index 4c2c1afe..a5908dae 100644 --- a/components/site/tests/common.rs +++ b/components/site/tests/common.rs @@ -1,3 +1,4 @@ +#![allow(dead_code)] use std::env; use std::path::PathBuf;