Files
clang-p2996/lldb/test/API/commands/trace/TestTraceSchema.py
Dave Lee 4cc8f2a017 [lldb][tests] Automatically call compute_mydir (NFC)
Eliminate boilerplate of having each test manually assign to `mydir` by calling
`compute_mydir` in lldbtest.py.

Differential Revision: https://reviews.llvm.org/D128077
2022-06-17 14:34:49 -07:00

27 lines
825 B
Python

import lldb
from intelpt_testcase import *
from lldbsuite.test.lldbtest import *
from lldbsuite.test import lldbutil
from lldbsuite.test.decorators import *
class TestTraceLoad(TraceIntelPTTestCaseBase):
def testSchema(self):
self.expect("trace schema intel-pt", substrs=["triple", "threads", "iptTrace"])
def testInvalidPluginSchema(self):
self.expect("trace schema invalid-plugin", error=True,
substrs=['error: no trace plug-in matches the specified type: "invalid-plugin"'])
def testAllSchemas(self):
self.expect("trace schema all", substrs=['''{
"type": "intel-pt",
"cpuInfo": {
// CPU information gotten from, for example, /proc/cpuinfo.
"vendor": "GenuineIntel" | "unknown",
"family": integer,
"model": integer,
"stepping": integer
},'''])