add test case for truncate

This commit is contained in:
harttle
2017-07-13 16:28:32 +08:00
parent 29fe8dcb4b
commit 9f82aec569
+3
View File
@@ -297,6 +297,9 @@ describe('filters', function () {
return test('{{ "Ground control to Major Tom." | truncate: 20, "" }}',
'Ground control to Ma')
})
it('should not truncate when short enough', function () {
return test('{{ "12345" | truncate: 5 }}', '12345')
})
})
describe('truncatewords', function () {