import React from 'react'; import { isTruthyReactNode } from '../isTruthyNode'; describe('isTruthyReactNode', () => { it('should return false for null', () => { expect(isTruthyReactNode(null)).toBe(false); }); it('should return false for undefined', () => { expect(isTruthyReactNode(undefined)).toBe(false); }); it('should return false for false', () => { expect(isTruthyReactNode(false)).toBe(false); }); it('should return true for true', () => { expect(isTruthyReactNode(true)).toBe(true); }); it('should return true for string', () => { expect(isTruthyReactNode('hello')).toBe(true); }); it('should return true for empty string', () => { expect(isTruthyReactNode('')).toBe(true); }); it('should return true for number', () => { expect(isTruthyReactNode(42)).toBe(true); }); it('should return true for zero', () => { expect(isTruthyReactNode(0)).toBe(true); }); it('should return true for React element', () => { const element =