Files
vscode-template-file-generator/src/test/extension.test.ts

23 lines
611 B
TypeScript
Raw Normal View History

import * as assert from 'assert';
import * as vscode from 'vscode';
import { CASE_MODIFIERS } from '@gromlab/create';
suite('Extension Test Suite', () => {
vscode.window.showInformationMessage('Start all tests.');
test('Sample test', () => {
assert.strictEqual(-1, [1, 2, 3].indexOf(5));
assert.strictEqual(-1, [1, 2, 3].indexOf(0));
});
});
suite('Template Variable Modifiers', () => {
const input = 'my super-name';
test('CASE_MODIFIERS map covers all', () => {
for (const [mod, fn] of Object.entries(CASE_MODIFIERS)) {
assert.strictEqual(typeof fn(input), 'string');
}
});
});