mirror of
https://github.com/toss/es-toolkit.git
synced 2024-12-01 02:33:54 +03:00
test(capitalize): Add lodash test case (#515)
Co-authored-by: dayongkr <dayongkr@gmail.com>
This commit is contained in:
parent
9aa89a7cfb
commit
e264ed6cf0
10
src/compat/string/capitalize.spec.ts
Normal file
10
src/compat/string/capitalize.spec.ts
Normal file
@ -0,0 +1,10 @@
|
||||
import { describe, it, expect } from 'vitest';
|
||||
import { capitalize } from '../../string/capitalize';
|
||||
|
||||
describe('capitalize', () => {
|
||||
it('should capitalize the first character of a string', () => {
|
||||
expect(capitalize('fred')).toBe('Fred');
|
||||
expect(capitalize('Fred')).toBe('Fred');
|
||||
expect(capitalize(' fred')).toBe(' fred');
|
||||
});
|
||||
});
|
Loading…
Reference in New Issue
Block a user