import { render } from '@testing-library/react';
import { describe, it, expect } from 'vitest';
import { Separator } from './separator';
import React from 'react';

describe('Separator', () => {
  it('renders correctly', () => {
    const { container } = render(<Separator />);
    expect(container.querySelector('[data-slot="separator-root"]')).toBeInTheDocument();
  });

  it('applies horizontal orientation by default', () => {
    const { container } = render(<Separator />);
    const separator = container.querySelector('[data-slot="separator-root"]');
    expect(separator).toHaveAttribute('data-orientation', 'horizontal');
  });

  it('applies vertical orientation correctly', () => {
    const { container } = render(<Separator orientation="vertical" />);
    const separator = container.querySelector('[data-slot="separator-root"]');
    expect(separator).toHaveAttribute('data-orientation', 'vertical');
  });
});
