From fdbff2afed6e7f39183de1f6118de71e36874ae8 Mon Sep 17 00:00:00 2001 From: Greg Clayton Date: Fri, 10 Jul 2015 00:30:22 +0000 Subject: Don't let a test fail because of a teardown command returning an error. Use a function that doesn't check the return value. llvm-svn: 241879 --- lldb/test/api/check_public_api_headers/TestPublicAPIHeaders.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'lldb/test/api/check_public_api_headers/TestPublicAPIHeaders.py') diff --git a/lldb/test/api/check_public_api_headers/TestPublicAPIHeaders.py b/lldb/test/api/check_public_api_headers/TestPublicAPIHeaders.py index 63e21ffb4f4..0a2c4a1b1d5 100644 --- a/lldb/test/api/check_public_api_headers/TestPublicAPIHeaders.py +++ b/lldb/test/api/check_public_api_headers/TestPublicAPIHeaders.py @@ -21,8 +21,6 @@ class SBDirCheckerCase(TestBase): self.exe_name = 'a.out' @skipIfNoSBHeaders - @skipIfDarwin # test passes but teardown command 'settings remove target.env-vars DYLD_LIBRARY_PATH' fails - # (expectedFailureDarwin doesn't work for teardown failures) def test_sb_api_directory(self): """Test the SB API directory and make sure there's no unwanted stuff.""" @@ -75,7 +73,7 @@ class SBDirCheckerCase(TestBase): if self.TraceOn(): print "Set environment to: ", env_cmd self.runCmd(env_cmd) - self.addTearDownHook(lambda: self.runCmd("settings remove target.env-vars %s" % self.dylibPath)) + self.addTearDownHook(lambda: self.dbg.HandleCommand("settings remove target.env-vars %s" % self.dylibPath)) lldbutil.run_break_set_by_file_and_line (self, self.source, self.line_to_break, num_expected_locations = -1) -- cgit v1.2.1