import React from 'react';
import renderer from 'react-test-renderer';
import { Radio } from '../../../';

describe('Radio Component', () => {
    it('renders correctly with label and active', () => {
        const tree = renderer.create(<Radio active={true} label="Example Label" />).toJSON();
        expect(tree).toMatchSnapshot();
    });

    it('renders correctly with label and inactive', () => {
        const tree = renderer.create(<Radio active={false} label="Example Label" />).toJSON();
        expect(tree).toMatchSnapshot();
    });

    it('renders correctly without label and active', () => {
        const tree = renderer.create(<Radio active={true} />).toJSON();
        expect(tree).toMatchSnapshot();
    });

    it('renders correctly without label and inactive', () => {
        const tree = renderer.create(<Radio active={false} />).toJSON();
        expect(tree).toMatchSnapshot();
    });

    it('renders correctly when disabled and active', () => {
        const tree = renderer.create(<Radio active={true} disabled />).toJSON();
        expect(tree).toMatchSnapshot();
    });

    it('renders correctly when disabled and inactive', () => {
        const tree = renderer.create(<Radio active={false} disabled />).toJSON();
        expect(tree).toMatchSnapshot();
    });
});
