lldb/test/API/commands/platform/file/close/TestPlatformFileClose.py
raw| 1 | import lldb |
| 2 | from lldbsuite.test.decorators import * |
| 3 | from lldbsuite.test.lldbtest import * |
| 4 | from lldbsuite.test import lldbutil |
| 5 | |
| 6 | |
| 7 | class TestCase(TestBase): |
| 8 | @no_debug_info_test |
| 9 | def test_file_close_invalid_arg(self): |
| 10 | self.expect( |
| 11 | "platform file close y", |
| 12 | error=True, |
| 13 | substrs=["'y' is not a valid file descriptor."], |
| 14 | ) |
| 15 | self.expect( |
| 16 | "platform file close -1", |
| 17 | error=True, |
| 18 | substrs=["'-1' is not a valid file descriptor."], |
| 19 | ) |