lib/tests/util/support/Rehydratable.test.ts

16 lines
403 B
TypeScript
Raw Normal View History

2021-11-26 20:31:59 +00:00
import { expect } from 'chai'
import { isJSONState } from '../../../lib'
describe('util -> support -> Rehydratable -> isJSONState', () => {
it('should return true for valid JSON', () => {
expect(isJSONState('this is a string'))
.to.be.true
expect(isJSONState(1234))
.to.be.true
expect(isJSONState({ name: true }))
.to.be.true
})
})