flydrive
Version:
File storage library with unified API to manage files across multiple cloud storage providers like S3, GCS, R2 and so on
27 lines (26 loc) • 796 B
TypeScript
import { Disk } from './disk.js';
import { FSDriver } from '../drivers/fs/driver.js';
import type { DriveManagerOptions } from './types.js';
/**
* FakeDisk extends the Disk class with additional capabilities to
* write assertions.
*/
export declare class FakeDisk extends Disk {
disk: string;
driver: FSDriver;
constructor(disk: string, fakesConfig: Exclude<DriveManagerOptions<any>['fakes'], undefined>);
/**
* Assert the expected file(s) exists. Otherwise an assertion
* error is thrown
*/
assertExists(paths: string | string[]): void;
/**
* Assert the expected file(s) to not exist. Otherwise an assertion
* error is thrown
*/
assertMissing(paths: string | string[]): void;
/**
* Clear storage
*/
clear(): void;
}