feat(comment): add comment on on interface method

This commit is contained in:
Oleksandr Smirnov 2025-09-04 14:17:58 +03:00
parent 26207b1928
commit 3cd45c45a3
No known key found for this signature in database
9 changed files with 91 additions and 13 deletions

View file

@ -22,4 +22,28 @@ utils["should .trimend()"] = function()
t.eq(u.trimend " hi ", " hi")
end
utils["should add .indent() spaces"] = function()
local u = require "gopher._utils"
local line = " func Test() error {"
local indent = 4
t.eq(" ", u.indent(line, indent))
end
utils["should add .indent() a tab"] = function()
local u = require "gopher._utils"
local line = "\tfunc Test() error {"
local indent = 1
t.eq("\t", u.indent(line, indent))
end
utils["should add .indent() 2 tabs"] = function()
local u = require "gopher._utils"
local line = "\t\tfunc Test() error {"
local indent = 2
t.eq("\t\t", u.indent(line, indent))
end
return T