28 lines · python
1"""2Test calling an expression without a target.3"""4 5 6import lldb7from lldbsuite.test.decorators import *8from lldbsuite.test.lldbtest import *9from lldbsuite.test import lldbutil10 11 12class TestCalculatorMode(TestBase):13 NO_DEBUG_INFO_TESTCASE = True14 15 def test__calculator_mode(self):16 """Test calling expressions in the dummy target."""17 self.expect(18 "expression 11 + 22",19 "11 + 22 didn't get the expected result",20 substrs=["33"],21 )22 # Now try it with a specific language:23 self.expect(24 "expression -l c -- 11 + 22",25 "11 + 22 didn't get the expected result",26 substrs=["33"],27 )28