We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent dde88dd commit d60ca79Copy full SHA for d60ca79
test/structures/enum_attrs.lua
@@ -67,7 +67,7 @@ end
67
68
function test.ipairs()
69
local i = 0
70
- for index in ipairs(df.item_type.attrs) do
+ for index, value in ipairs(df.item_type.attrs) do
71
if i == 0 then
72
expect.eq(index, df.item_type._first_item, 'ipairs() returned wrong start index')
73
end
@@ -76,6 +76,8 @@ function test.ipairs()
76
expect.fail('ipairs() returned too many items: ' .. tostring(i))
77
break
78
79
+ expect.eq(value, df.item_type.attrs[i + df.item_type._first_item],
80
+ 'ipairs() returned incorrect attrs for item at index: ' .. tostring(index))
81
82
expect.eq(i, max_attrs_length(df.item_type))
83
0 commit comments