import '@testing-library/jest-dom/vitest';
import { render } from '@testing-library/vue';
import { describe, expect, test } from 'vitest';
import UiCardTitle from '../UiCardTitle.vue';

describe('UiCardTitle', () => {
  test('renders with custom class', () => {
    const { container } = render(UiCardTitle, {
      props: { class: 'custom-title' },
      slots: {
        default: 'Card Title',
      },
    });

    const title = container.querySelector('[data-slot="card-title"]');
    expect(title).toBeInTheDocument();
    expect(title).toHaveClass('custom-title');
  });
});
