diff --git a/selene-lib/tests/lints/divide_by_zero/divide_by_zero.lua b/selene-lib/tests/lints/divide_by_zero/divide_by_zero.lua index 5e902c2b..9b9422ce 100644 --- a/selene-lib/tests/lints/divide_by_zero/divide_by_zero.lua +++ b/selene-lib/tests/lints/divide_by_zero/divide_by_zero.lua @@ -3,3 +3,4 @@ local _ = 5 / 0 local _ = 0 / 5 local _ = x / 0 local _ = 0 / 0 +local _ = -1 / 0 \ No newline at end of file diff --git a/selene-lib/tests/lints/divide_by_zero/divide_by_zero.stderr b/selene-lib/tests/lints/divide_by_zero/divide_by_zero.stderr index b645f171..67b56525 100644 --- a/selene-lib/tests/lints/divide_by_zero/divide_by_zero.stderr +++ b/selene-lib/tests/lints/divide_by_zero/divide_by_zero.stderr @@ -10,3 +10,9 @@ error[divide_by_zero]: dividing by zero is not allowed, use math.huge instead 4 │ local _ = x / 0 │ ^^^^^ +error[divide_by_zero]: dividing by zero is not allowed, use math.huge instead + ┌─ divide_by_zero.lua:6:11 + │ +6 │ local _ = -1 / 0 + │ ^^^^^^ +