Skip to content

Commit

Permalink
Fix test accoriing to changes on the component
Browse files Browse the repository at this point in the history
Signed-off-by: angatupyry <fierrofenix@gmail.com>
  • Loading branch information
Angatupyry committed Sep 18, 2023
1 parent c035417 commit 006c636
Showing 1 changed file with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ describe('EventEditDeletePopup', () => {
const currentValue = 'current';
const allValue = 'all';
const value = 'current';
const deleting = true;
const onChange = jasmine.createSpy('onChange');

it('handles onChange event', () => {
Expand All @@ -15,13 +14,12 @@ describe('EventEditDeletePopup', () => {
currentValue={currentValue}
allValue={allValue}
value={value}
deleting={deleting}
onChange={onChange}
/>,
);

// Simulate a change event by clicking on a radio button
fireEvent.click(getByLabelText(`All events`));
fireEvent.click(getByLabelText('All events in this schedule'));

// Check if the onChange function was called with the correct value
expect(onChange).toHaveBeenCalled();
Expand Down

0 comments on commit 006c636

Please sign in to comment.