r = new Error(`ENOENT: no such file or directory, unlink '${filepath}'`)
          err.code = 'ENOENT'
          err.errno = -2
          throw err
        }
        this.entries.delete(normalizedPath)
        this.modified.add(normalizedPath)
      }

      async rmdir(dirpath) {
        const normalizedPath = this._normalizePath(dirpath)
        const dirPath = normalizedPath.endsWith('/') ? normalizedPath : normalizedPath + '/'

        const children = await this.readdir(dirpath)
        if (children.le