Skip to content

Commit 636cdde

Browse files
committed
Make test more robust
1 parent de3346a commit 636cdde

File tree

2 files changed

+12
-12
lines changed

2 files changed

+12
-12
lines changed

lldb/test/API/lang/swift/variables/inout/TestInOutVariables.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -72,19 +72,19 @@ def check_class_internal(
7272

7373
ivar = x_actual.GetChildAtIndex(0).GetChildAtIndex(0)
7474
ovar = x_actual.GetChildAtIndex(1)
75-
self.assertTrue(
76-
ivar.GetName() == "ivar", "Name: %s is not ivar %s" %
75+
self.assertEquals(
76+
ivar.GetName(), "ivar", "Name: %s is not ivar %s" %
7777
(ivar.GetName(), message_end))
78-
self.assertTrue(
79-
ovar.GetName() == "ovar",
78+
self.assertEquals(
79+
ovar.GetName(), "ovar",
8080
"ovar is not ovar %s" %
8181
(message_end))
82-
self.assertTrue(
83-
ivar.GetValue() == ivar_value,
82+
self.assertEquals(
83+
ivar.GetValue(), ivar_value,
8484
"ivar wrong %s" %
8585
(message_end))
86-
self.assertTrue(
87-
ovar.GetValue() == ovar_value,
86+
self.assertEquals(
87+
ovar.GetValue(), ovar_value,
8888
"ovar wrong %s" %
8989
(message_end))
9090

lldb/test/API/lang/swift/variables/inout/main.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,13 +39,13 @@ struct Struct {
3939
}
4040

4141
func foo (_ x: inout Class) {
42-
print(x.ivar)
43-
x.ivar += 1 // Set breakpoint here for Class access
42+
print(x.ivar) // Set breakpoint here for Class access
43+
x.ivar += 1
4444
}
4545

4646
func foo(_ x: inout Struct) {
47-
print(x.ivar)
48-
x.ivar += 1 // Set breakpoint here for Struct access
47+
print(x.ivar) // Set breakpoint here for Struct access
48+
x.ivar += 1
4949
}
5050

5151
func fn_ptrs (_ str: Struct) {

0 commit comments

Comments
 (0)