(testName, input, expected)
| 25 | } |
| 26 | |
| 27 | const testIdent = function (testName, input, expected) { |
| 28 | test(testName, function () { |
| 29 | const client = new Client(helper.config) |
| 30 | const actual = client.escapeIdentifier(input) |
| 31 | assert.equal(expected, actual) |
| 32 | }) |
| 33 | |
| 34 | test('Client.prototype.' + testName, function () { |
| 35 | const actual = Client.prototype.escapeIdentifier(input) |
| 36 | assert.equal(expected, actual) |
| 37 | }) |
| 38 | |
| 39 | test('utils.' + testName, function () { |
| 40 | const actual = utils.escapeIdentifier(input) |
| 41 | assert.equal(expected, actual) |
| 42 | }) |
| 43 | } |
| 44 | |
| 45 | testLit('escapeLiteral: no special characters', 'hello world', "'hello world'") |
| 46 |
no test coverage detected