diff --git a/Cargo.lock b/Cargo.lock index a20a0b57080..c4175cb9704 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2891,13 +2891,6 @@ dependencies = [ "xdg 2.1.0 (registry+https://github.com/rust-lang/crates.io-index)", ] -[[package]] -name = "servo_config_tests" -version = "0.0.1" -dependencies = [ - "servo_config 0.0.1", -] - [[package]] name = "servo_geometry" version = "0.0.1" diff --git a/components/config/Cargo.toml b/components/config/Cargo.toml index e09c78ecbb8..1d5c48d605f 100644 --- a/components/config/Cargo.toml +++ b/components/config/Cargo.toml @@ -8,6 +8,8 @@ publish = false [lib] name = "servo_config" path = "lib.rs" +test = false +doctest = false [dependencies] euclid = "0.16" diff --git a/tests/unit/servo_config/opts.rs b/components/config/tests/opts.rs similarity index 99% rename from tests/unit/servo_config/opts.rs rename to components/config/tests/opts.rs index b533429df5b..53a049e103c 100644 --- a/tests/unit/servo_config/opts.rs +++ b/components/config/tests/opts.rs @@ -2,6 +2,8 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +extern crate servo_config; + use servo_config::opts::{parse_url_or_filename, parse_pref_from_command_line}; use servo_config::prefs::{PrefValue, PREFS}; use std::path::Path; diff --git a/tests/unit/servo_config/prefs.rs b/components/config/tests/prefs.rs similarity index 98% rename from tests/unit/servo_config/prefs.rs rename to components/config/tests/prefs.rs index 8b6b7295815..c9857345bb2 100644 --- a/tests/unit/servo_config/prefs.rs +++ b/components/config/tests/prefs.rs @@ -2,6 +2,8 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +extern crate servo_config; + use servo_config::basedir; use servo_config::prefs::{PREFS, PrefValue, read_prefs_from_file}; use std::fs::{self, File}; diff --git a/python/servo/testing_commands.py b/python/servo/testing_commands.py index 0739501a42f..96f7ce784f1 100644 --- a/python/servo/testing_commands.py +++ b/python/servo/testing_commands.py @@ -231,7 +231,15 @@ class MachCommands(CommandBase): else: test_patterns.append(test) - self_contained_tests = ["gfx", "layout", "msg", "net", "net_traits", "selectors"] + self_contained_tests = [ + "gfx", + "layout", + "msg", + "net", + "net_traits", + "selectors", + "servo_config", + ] if not packages: packages = set(os.listdir(path.join(self.context.topdir, "tests", "unit"))) - set(['.DS_Store']) packages |= set(self_contained_tests) diff --git a/tests/unit/servo_config/Cargo.toml b/tests/unit/servo_config/Cargo.toml deleted file mode 100644 index dec49de186a..00000000000 --- a/tests/unit/servo_config/Cargo.toml +++ /dev/null @@ -1,14 +0,0 @@ -[package] -name = "servo_config_tests" -version = "0.0.1" -authors = ["The Servo Project Developers"] -license = "MPL-2.0" - -[lib] -name = "servo_config_tests" -path = "lib.rs" -doctest = false - -[dependencies] -servo_config = {path = "../../../components/config"} - diff --git a/tests/unit/servo_config/lib.rs b/tests/unit/servo_config/lib.rs deleted file mode 100644 index dc2a6446848..00000000000 --- a/tests/unit/servo_config/lib.rs +++ /dev/null @@ -1,10 +0,0 @@ -/* This Source Code Form is subject to the terms of the Mozilla Public - * License, v. 2.0. If a copy of the MPL was not distributed with this - * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ - -#![cfg(test)] - -extern crate servo_config; - -mod opts; -mod prefs;