mirror of
https://github.com/gitbutlerapp/gitbutler.git
synced 2024-12-25 10:33:21 +03:00
feat: add a few string tests
This commit is contained in:
parent
3eed596cc8
commit
02d5a88612
24
packages/ui/src/lib/utils/string.test.ts
Normal file
24
packages/ui/src/lib/utils/string.test.ts
Normal file
@ -0,0 +1,24 @@
|
||||
import { camelCaseToTitleCase } from './string';
|
||||
import { describe, expect, test } from 'vitest';
|
||||
|
||||
describe.concurrent('Commit types handled correctly', () => {
|
||||
test('localAndRemote', () => {
|
||||
expect(camelCaseToTitleCase('localAndRemote')).toEqual('Local And Remote');
|
||||
});
|
||||
|
||||
test('local', () => {
|
||||
expect(camelCaseToTitleCase('local')).toEqual('Local');
|
||||
});
|
||||
|
||||
test('remote', () => {
|
||||
expect(camelCaseToTitleCase('remote')).toEqual('Remote');
|
||||
});
|
||||
|
||||
test('localAndShadow', () => {
|
||||
expect(camelCaseToTitleCase('localAndShadow')).toEqual('Local And Shadow');
|
||||
});
|
||||
|
||||
test('LocalAndShadow', () => {
|
||||
expect(camelCaseToTitleCase('LocalAndShadow')).toEqual('Local And Shadow');
|
||||
});
|
||||
});
|
Loading…
Reference in New Issue
Block a user