Skip to content

Commit

Permalink
Adds toSpreadRest to Combobox & DatePicker
Browse files Browse the repository at this point in the history
  • Loading branch information
TheSonOfThomp committed Feb 15, 2024
1 parent 2e2bfae commit cf8994c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/combobox/src/Combobox/Combobox.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ import {
testif,
} from '../utils/ComboboxTestUtils';

import { Combobox } from './Combobox';

/**
* Tests
*/
Expand Down Expand Up @@ -70,6 +72,8 @@ describe('packages/combobox', () => {
: testif(select === 'multiple')(name, fn);

describe('Basic rendering', () => {
test('spreads rest', () => expect(Combobox).toSpreadRest());

// Label prop
test('Label is rendered', () => {
const { labelEl } = renderCombobox(select, { label: 'Some label' });
Expand Down
2 changes: 2 additions & 0 deletions packages/date-picker/src/DatePicker/DatePicker.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ describe('packages/date-picker', () => {
/// Note: Many rendering tests should be handled by Chromatic

describe('Input', () => {
test('spreads rest', () => expect(DatePicker).toSpreadRest());

test('renders label', () => {
const { getByText } = render(<DatePicker label="Label" />);
const label = getByText('Label');
Expand Down

0 comments on commit cf8994c

Please sign in to comment.