angular unit test: How to mock up a FileList in Jest?

I'm trying to create a Jest unit test for an field used for uploading files.
I would like to mock up a FileList object containing image files.

uploadImage(files: FileList) {
  this.uploadError = '';

  if (files.length <= 0) {

  const file = files[0];

  if (/^[A-Za-z0-9!-_.'()]/.test( {
    this.uploadError = 'Invalid characters...';
    return false;

  if (file.size >= LIMIT_SIZE_IMAGE) {
    this.uploadError = 'Limit size exceeded...';
    return false;


Since FileList is readonly, I can't create it by calling

new FileList([...files])

Which brings me to my question - how does one create a testable mock object? Any ideas?