[Lldb-commits] [lldb] [lldb] Fixed unresolved test lldb-api python_api/debugger/TestDebuggerAPI.py on x86_64 host (PR #90580)

2024-05-16 Thread Dmitry Vasilyev via lldb-commits

slydiman wrote:

I have added [the issuee](https://github.com/llvm/llvm-project/issues/92419)  
and updated the test with @expectedFailureAll and the bugnumber.

https://github.com/llvm/llvm-project/pull/90580
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb] Fixed unresolved test lldb-api python_api/debugger/TestDebuggerAPI.py on x86_64 host (PR #90580)

2024-05-16 Thread Dmitry Vasilyev via lldb-commits

https://github.com/slydiman updated 
https://github.com/llvm/llvm-project/pull/90580

>From 0d6ff964ed83e06ed3947d709884ed6dd43e90b5 Mon Sep 17 00:00:00 2001
From: Dmitry Vasilyev 
Date: Tue, 30 Apr 2024 13:42:45 +0400
Subject: [PATCH 1/2] [lldb][Windows] Fixed unresolved test lldb-api
 python_api/debugger/TestDebuggerAPI.py

It is necessary to select the expected platform at the beginning.
In case of `Windows` host platform1.GetName() returned `host`. 
platform2.GetName() returned `remote-linux`, but 
platform2.GetWorkingDirectory() was None and finally
```
  File "llvm-project\lldb\test\API\python_api\debugger\TestDebuggerAPI.py", 
line 108, in test_CreateTarget_platform
platform2.GetWorkingDirectory().endswith("bar"),
AttributeError: 'NoneType' object has no attribute 'endswith'
```
---
 lldb/test/API/python_api/debugger/TestDebuggerAPI.py | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lldb/test/API/python_api/debugger/TestDebuggerAPI.py 
b/lldb/test/API/python_api/debugger/TestDebuggerAPI.py
index 522de2466012e..3d6484e5c9fbc 100644
--- a/lldb/test/API/python_api/debugger/TestDebuggerAPI.py
+++ b/lldb/test/API/python_api/debugger/TestDebuggerAPI.py
@@ -95,6 +95,7 @@ def test_CreateTarget_platform(self):
 exe = self.getBuildArtifact("a.out")
 self.yaml2obj("elf.yaml", exe)
 error = lldb.SBError()
+self.dbg.SetSelectedPlatform(lldb.SBPlatform("remote-linux"))
 target1 = self.dbg.CreateTarget(exe, None, "remote-linux", False, 
error)
 self.assertSuccess(error)
 platform1 = target1.GetPlatform()

>From 012d95b3ed4c83c9d439cae1e2b53cbea5dcb441 Mon Sep 17 00:00:00 2001
From: Dmitry Vasilyev 
Date: Thu, 16 May 2024 21:25:51 +0400
Subject: [PATCH 2/2] Updated to use @expectedFailureAll with a bugnumber.

---
 lldb/test/API/python_api/debugger/TestDebuggerAPI.py | 6 +-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/lldb/test/API/python_api/debugger/TestDebuggerAPI.py 
b/lldb/test/API/python_api/debugger/TestDebuggerAPI.py
index 3d6484e5c9fbc..55071d6da8f8a 100644
--- a/lldb/test/API/python_api/debugger/TestDebuggerAPI.py
+++ b/lldb/test/API/python_api/debugger/TestDebuggerAPI.py
@@ -91,11 +91,15 @@ def get_cache_line_size():
 # Test the local property again, is it set to new_cache_line_size?
 self.assertEqual(get_cache_line_size(), new_cache_line_size)
 
+@expectedFailureAll(
+hostoslist=["windows"],
+remote=True,
+bugnumber="github.com/llvm/llvm-project/issues/92419",
+)
 def test_CreateTarget_platform(self):
 exe = self.getBuildArtifact("a.out")
 self.yaml2obj("elf.yaml", exe)
 error = lldb.SBError()
-self.dbg.SetSelectedPlatform(lldb.SBPlatform("remote-linux"))
 target1 = self.dbg.CreateTarget(exe, None, "remote-linux", False, 
error)
 self.assertSuccess(error)
 platform1 = target1.GetPlatform()

___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb] Fixed unresolved test lldb-api python_api/debugger/TestDebuggerAPI.py on x86_64 host (PR #90580)

2024-05-03 Thread Pavel Labath via lldb-commits

labath wrote:

FWIW, I agree with @bulbazord. If the user specifies an explicit platform in 
the CreateTarget function, that platform should really take precedence over 
anything else.
(If it were up to me, I would not even attempt matching other platforms in this 
case (and just refuse to create the target if the provided platform does not 
work), but that might be going too far in terms of changing existing behavior).

https://github.com/llvm/llvm-project/pull/90580
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb] Fixed unresolved test lldb-api python_api/debugger/TestDebuggerAPI.py on x86_64 host (PR #90580)

2024-05-01 Thread Dmitry Vasilyev via lldb-commits

https://github.com/slydiman edited 
https://github.com/llvm/llvm-project/pull/90580
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits