Test migration to jest by hand
Apparently using regular expressions is way easier.
This commit is contained in:
9
test/escapeRegExp/escapeRegExp.test.js
Normal file
9
test/escapeRegExp/escapeRegExp.test.js
Normal file
@ -0,0 +1,9 @@
|
||||
const expect = require('expect');
|
||||
const escapeRegExp = require('./escapeRegExp.js');
|
||||
|
||||
|
||||
test('escapeRegExp is a Function', () => {
|
||||
expect(escapeRegExp).toBeInstanceOf(Function);
|
||||
});
|
||||
t.equal(escapeRegExp('(test)'), '\\(test\\)', "Escapes a string to use in a regular expression");
|
||||
|
||||
Reference in New Issue
Block a user