diff options
| author | yukang <moorekang@gmail.com> | 2023-03-29 00:36:10 +0800 |
|---|---|---|
| committer | yukang <moorekang@gmail.com> | 2023-04-27 00:15:55 +0800 |
| commit | d8faf3eb3f4a4b3d1c2908fb3868a7108bebe88a (patch) | |
| tree | 07bbcdcb70e237b259c0488ce9abea9fcbe14508 | |
| parent | 89566d5a9b7c71ff528bf7e6e7c60f536f467a5d (diff) | |
| download | rust-d8faf3eb3f4a4b3d1c2908fb3868a7108bebe88a.tar.gz rust-d8faf3eb3f4a4b3d1c2908fb3868a7108bebe88a.zip | |
add test
| -rw-r--r-- | src/bootstrap/bootstrap_test.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/bootstrap/bootstrap_test.py b/src/bootstrap/bootstrap_test.py index 26bd80a008f..1e46348577d 100644 --- a/src/bootstrap/bootstrap_test.py +++ b/src/bootstrap/bootstrap_test.py @@ -112,6 +112,12 @@ class GenerateAndParseConfig(unittest.TestCase): build = self.serialize_and_parse(["--set", "profile=compiler"]) self.assertEqual(build.get_toml("profile"), 'compiler') + def test_set_codegen_backends(self): + build = self.serialize_and_parse(["--set", "rust.codegen-backends=cranelift"]) + self.assertNotEqual(build.config_toml.find("codegen-backends = ['cranelift']"), -1) + build = self.serialize_and_parse(["--set", "rust.codegen-backends=cranelift,llvm"]) + self.assertNotEqual(build.config_toml.find("codegen-backends = ['cranelift', 'llvm']"), -1) + if __name__ == '__main__': SUITE = unittest.TestSuite() TEST_LOADER = unittest.TestLoader() |
