diff options
Diffstat (limited to 'testes')
-rw-r--r-- | testes/db.lua | 2 | ||||
-rw-r--r-- | testes/gc.lua | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/testes/db.lua b/testes/db.lua index e0699724..f891e9b8 100644 --- a/testes/db.lua +++ b/testes/db.lua | |||
@@ -887,7 +887,7 @@ do -- testing debug info for finalizers | |||
887 | 887 | ||
888 | -- create a piece of garbage with a finalizer | 888 | -- create a piece of garbage with a finalizer |
889 | setmetatable({}, {__gc = function () | 889 | setmetatable({}, {__gc = function () |
890 | local t = debug.getinfo(2) -- get callee information | 890 | local t = debug.getinfo(1) -- get function information |
891 | assert(t.namewhat == "metamethod") | 891 | assert(t.namewhat == "metamethod") |
892 | name = t.name | 892 | name = t.name |
893 | end}) | 893 | end}) |
diff --git a/testes/gc.lua b/testes/gc.lua index d865cb28..381c5548 100644 --- a/testes/gc.lua +++ b/testes/gc.lua | |||
@@ -371,7 +371,7 @@ if T then | |||
371 | 371 | ||
372 | warn("@on"); warn("@store") | 372 | warn("@on"); warn("@store") |
373 | collectgarbage() | 373 | collectgarbage() |
374 | assert(string.find(_WARN, "error in __gc metamethod")) | 374 | assert(string.find(_WARN, "error in __gc")) |
375 | assert(string.match(_WARN, "@(.-)@") == "expected"); _WARN = false | 375 | assert(string.match(_WARN, "@(.-)@") == "expected"); _WARN = false |
376 | for i = 8, 10 do assert(s[i]) end | 376 | for i = 8, 10 do assert(s[i]) end |
377 | 377 | ||