utils/ts-src/hasOwn.test.ts
Martin Donnelly c30b36b3f6 init
2020-11-17 11:16:34 +00:00

14 lines
290 B
TypeScript

import { hasOwn } from './hasOwn';
let testObj: Object = {
bob: true
};
test('It has a specified property', function () {
expect(hasOwn(testObj, 'bob')).toBeTruthy();
});
test('It does not have a specified property', function () {
expect(hasOwn(testObj, 'Steve')).toBeFalsy();
});