1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-11-26 22:41:17 +02:00

Chore: Fixed build

This commit is contained in:
Laurent Cozic
2023-03-19 17:03:04 +00:00
parent 3e52411bc4
commit 28a24d8c03
5 changed files with 746 additions and 1 deletions

View File

@@ -0,0 +1,19 @@
import commandToString from './commandToString';
describe('commandToString', () => {
it('should convert a command array to a string', () => {
const testCases: [string, string[], string][] = [
['ls', ['-la'], 'ls -la'],
['docker', ['--profile', 'with spaces'], 'docker --profile "with spaces"'],
['', [], ''],
['', [''], ''],
];
for (const [commandName, args, expected] of testCases) {
const actual = commandToString(commandName, args);
expect(actual).toBe(expected);
}
});
});