MCPcopy Create free account
hub / github.com/SplootCode/splootcode / testExpressionParsing

Method testExpressionParsing

python/tests/test_execute.py:194–203  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

192 })
193
194 def testExpressionParsing(self):
195 splootFile = splootFromPython('''print(100 + 10 + 10 + 4 * 3 * 2 + 10 + 10)''')
196
197 f = io.StringIO()
198 f.write = wrapStdout(f.write)
199 with contextlib.redirect_stdout(f):
200 executePythonFile(splootFile)
201
202 f.seek(0)
203 self.assertEqual(f.read(), '164\n')
204
205 def testExpressionParsingOrderOfOperations(self):
206 splootFile = splootFromPython('''print(100 * 100 == 10000)''')

Callers

nothing calls this directly

Calls 4

splootFromPythonFunction · 0.90
wrapStdoutFunction · 0.90
executePythonFileFunction · 0.90
readMethod · 0.80

Tested by

no test coverage detected