When using userEvent.upload, automatically discard files that don't match an accept property if it exists.
userEvent.upload
accept