diff --git a/Cargo.toml b/Cargo.toml index 5dc736c..aeea038 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -21,3 +21,4 @@ nix = { version = "0.26", features = ["process", "signal"] } prctl = "1.0" reqwest = { version = "0.11", features = ["blocking", "json"] } serial_test = "1.0" +test-log = "0.2" diff --git a/tests/proxy.rs b/tests/proxy.rs index 1462307..fe3125f 100644 --- a/tests/proxy.rs +++ b/tests/proxy.rs @@ -146,7 +146,11 @@ mod tests { } Ok(Fork::Child) => { prctl::set_death_signal(signal::SIGKILL as isize).unwrap(); // 9 == SIGKILL - main_entry(TUN_TEST_DEVICE, test.proxy, Options::new()); + main_entry( + TUN_TEST_DEVICE, + test.proxy, + Options::new().with_virtual_dns(), + ); } Err(_) => panic!(), } @@ -163,7 +167,7 @@ mod tests { } #[serial] - #[test] + #[test_log::test] fn test_socks5() { require_var("SOCKS5_SERVER"); run_test( @@ -173,7 +177,7 @@ mod tests { } #[serial] - #[test] + #[test_log::test] fn test_http() { require_var("HTTP_SERVER"); run_test( @@ -183,7 +187,7 @@ mod tests { } #[serial] - #[test] + #[test_log::test] fn test_socks5_dns() { require_var("SOCKS5_SERVER"); run_test( @@ -193,7 +197,7 @@ mod tests { } #[serial] - #[test] + #[test_log::test] fn test_http_dns() { require_var("HTTP_SERVER"); run_test(