Files
30-seconds-of-code/test/indentString/indentString.test.js
Angelos Chalaris 28e84d483c Add indentString
2018-09-24 22:14:27 +03:00

13 lines
417 B
JavaScript

const expect = require('expect');
const indentString = require('./indentString.js');
test('indentString is a Function', () => {
expect(indentString).toBeInstanceOf(Function);
});
test('indentString is a Function', () => {
expect(indentString('Lorem\nIpsum', 2)).toBe(' Lorem\n Ipsum');
});
test('indentString is a Function', () => {
expect(indentString('Lorem\nIpsum', 2, '_')).toBe('__Lorem\n__Ipsum');
});