Skip to content

Commit b69bfaf

Browse files
committed
Fix not-equal tests in Map unit test
1 parent bb38918 commit b69bfaf

2 files changed

Lines changed: 8 additions & 10 deletions

File tree

test/godot_project/gdscript/out/TestMap.gd

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ static func test() -> void:
6464

6565
var copied: StringMap = map.copy()
6666

67-
copied != map
67+
assert(copied != map, "Test assert failed.")
6868

6969
if true:
7070
var cond: bool = copied.exists("foo") == map.exists("foo")
@@ -243,7 +243,7 @@ static func test() -> void:
243243

244244
var copied2: IntMap = map6.copy()
245245

246-
copied2 != map6
246+
assert(copied2 != map6, "Test assert failed.")
247247

248248
if true:
249249
var cond: bool = copied2.exists(1) == map6.exists(1)
@@ -476,7 +476,7 @@ static func test() -> void:
476476

477477
var copied3: ObjectMap = map8.copy()
478478

479-
copied3 != map8
479+
assert(copied3 != map8, "Test assert failed.")
480480

481481
if true:
482482
var cond: bool = copied3.exists(a) == map8.exists(a)
@@ -656,7 +656,7 @@ static func test() -> void:
656656

657657
var copied4: ObjectMap = map9.copy()
658658

659-
copied4 != map9
659+
assert(copied4 != map9, "Test assert failed.")
660660

661661
if true:
662662
var cond: bool = copied4.exists(a2) == map9.exists(a2)
@@ -1094,5 +1094,3 @@ static func test() -> void:
10941094
if true:
10951095
var cond: bool = (["1a", "1b"] as Array[String]).has(tempArray15[1])
10961096
assert(cond, "Test assert failed.")
1097-
1098-
print("Map test reached end.");

test/src/test/TestMap.hx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ class TestMap {
3030
assert(map4.get("foo") == 1);
3131

3232
var copied = map.copy();
33-
copied != map;
33+
assert(copied != map);
3434
assert(copied.exists("foo") == map.exists("foo"));
3535
assert(copied.exists("bar") == map.exists("bar"));
3636
assert(copied.exists("baz") == map.exists("baz"));
@@ -87,7 +87,7 @@ class TestMap {
8787
assert(map.get(3) == 3);
8888

8989
var copied = map.copy();
90-
copied != map;
90+
assert(copied != map);
9191
assert(copied.exists(1) == map.exists(1));
9292
assert(copied.exists(2) == map.exists(2));
9393
assert(copied.exists(3) == map.exists(3));
@@ -154,7 +154,7 @@ class TestMap {
154154
assert([1,2,3].contains(values[2]));
155155

156156
var copied = map.copy();
157-
copied != map;
157+
assert(copied != map);
158158
assert(copied.exists(a) == map.exists(a));
159159
assert(copied.exists(b) == map.exists(b));
160160
assert(copied.exists(c) == map.exists(c));
@@ -213,7 +213,7 @@ class TestMap {
213213
assert([1,2,3].contains(values[2]));
214214

215215
var copied = map.copy();
216-
copied != map;
216+
assert(copied != map);
217217
assert(copied.exists(a) == map.exists(a));
218218
assert(copied.exists(b) == map.exists(b));
219219
assert(copied.exists(c) == map.exists(c));

0 commit comments

Comments
 (0)