Module:String2/testcases: Difference between revisions

Content deleted Content added
Add tests for sentence
remove unused bit
Line 1:
-- Unit tests for [[Module:{{ROOTPAGENAME}}]]. Click talk page to run tests.
local p = require('Module:UnitTests')
 
function p:preprocess_equal_stripmarkers(test, expected)
local frame = mw.getCurrentFrame()
test = frame:preprocess(test ):gsub('(\127\'"`UNIQ%-%-[a-z]+%-)[0-9A-Fa-f]+(%-QINU`"\'\127)', '%100000000%2')
expected = frame:preprocess(expected):gsub('(\127\'"`UNIQ%-%-[a-z]+%-)[0-9A-Fa-f]+(%-QINU`"\'\127)', '%100000000%2')
return self:equals(test, expected)
end
 
function p:test_matchAny()