mirror of
https://github.com/directus/directus.git
synced 2026-02-17 23:21:31 -05:00
Tests for pluralize, toArray, validateExtensionManifest, and parseFilter (#8276)
* pluralize tests passing, 100% coverage * toArray tests passing, 100% coverage * validate-extension-manifest tests passing, 100% coverage * parse-filter tests passing, coverage 100% * covered line 16
This commit is contained in:
11
packages/shared/src/utils/to-array.test.ts
Normal file
11
packages/shared/src/utils/to-array.test.ts
Normal file
@@ -0,0 +1,11 @@
|
||||
import { toArray } from '.';
|
||||
|
||||
describe('toArray', () => {
|
||||
it('takes in a string and returns an array', () => {
|
||||
expect(toArray('1,2,3,4,5')).toStrictEqual(['1', '2', '3', '4', '5']);
|
||||
});
|
||||
|
||||
it('when passed an array returns the array', () => {
|
||||
expect(toArray(['1', '2', '3', '4', '5'])).toStrictEqual(['1', '2', '3', '4', '5']);
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user