mirror of
https://github.com/shlinkio/shlink-web-client.git
synced 2025-01-03 23:07:26 +03:00
Added test for parseBooleanToString
This commit is contained in:
parent
1d6f4bf5db
commit
b00f6fadf8
1 changed files with 10 additions and 1 deletions
|
@ -1,4 +1,4 @@
|
|||
import { capitalize, nonEmptyValueOrNull, rangeOf } from '../../src/utils/utils';
|
||||
import { capitalize, nonEmptyValueOrNull, parseBooleanToString, rangeOf } from '../../src/utils/utils';
|
||||
|
||||
describe('utils', () => {
|
||||
describe('rangeOf', () => {
|
||||
|
@ -49,4 +49,13 @@ describe('utils', () => {
|
|||
expect(capitalize(value)).toEqual(expectedResult);
|
||||
});
|
||||
});
|
||||
|
||||
describe('parseBooleanToString', () => {
|
||||
it.each([
|
||||
[true, 'true'],
|
||||
[false, 'false'],
|
||||
])('parses value as expected', (value, expectedResult) => {
|
||||
expect(parseBooleanToString(value)).toEqual(expectedResult);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue