mirror of
https://github.com/siemens-mobile-hacks/llvm-c166.git
synced 2026-11-28 03:42:55 +00:00
A second pass over the full API suite for tests that depend on features
unavailable on wasm32-wasip1 or in LLDB's Wasm support:
- Expression evaluation (skipIfWasm) for the C++ tests that the
"expression" category doesn't cover, since that category only applies to
commands/expression/*.
- Attaching to a running process (skipIfWasm). These tests have the
harness spawn the inferior as a host process and then attach, but a
.wasm module isn't a native executable, so exec'ing it fails with
ENOEXEC ("Exec format error"). The wasm module only runs inside the
runtime (e.g. iwasm) that LLDB launches, so there is no host process to
attach to.
Where a test also has supported, passing cases, the decorator is applied
per method.
22 lines
777 B
Python
22 lines
777 B
Python
"""Test that decl lookup into submodules in C++ works as expected."""
|
|
|
|
import lldb
|
|
import shutil
|
|
|
|
from lldbsuite.test.decorators import *
|
|
from lldbsuite.test.lldbtest import *
|
|
from lldbsuite.test import lldbutil
|
|
|
|
|
|
@skipIfWasm # no expression evaluation
|
|
class DeclFromSubmoduleTestCase(TestBase):
|
|
# Requires DWARF debug info which is not retained when linking with link.exe.
|
|
@skipIfWindows
|
|
# Lookup for decls in submodules fails in Linux
|
|
@expectedFailureAll(oslist=["linux"])
|
|
def test_expr(self):
|
|
self.build()
|
|
lldbutil.run_to_source_breakpoint(self, "return 0", lldb.SBFileSpec("main.cpp"))
|
|
|
|
self.expect_expr("func(1, 2)", result_type="int", result_value="3")
|
|
self.expect_expr("func(1)", result_type="int", result_value="1")
|