Return of the test API and update readme
This commit is contained in:
parent
3b1e500317
commit
f6825bbadc
3 changed files with 66 additions and 8 deletions
27
src/tests/TestAPI.ts
Normal file
27
src/tests/TestAPI.ts
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
import {APIModel} from '../api/APIModel';
|
||||
import {MediaTypeModel} from '../models/MediaTypeModel';
|
||||
import MediaDbPlugin from '../main';
|
||||
|
||||
export class TestAPI extends APIModel {
|
||||
plugin: MediaDbPlugin;
|
||||
|
||||
|
||||
constructor(plugin: MediaDbPlugin) {
|
||||
super();
|
||||
|
||||
this.plugin = plugin;
|
||||
this.apiName = 'TestAPI';
|
||||
this.apiDescription = 'A test API for automated testing.';
|
||||
this.apiUrl = '';
|
||||
this.types = [];
|
||||
}
|
||||
|
||||
|
||||
async getById(item: MediaTypeModel): Promise<MediaTypeModel> {
|
||||
return undefined;
|
||||
}
|
||||
|
||||
async searchByTitle(title: string): Promise<MediaTypeModel[]> {
|
||||
return [] as MediaTypeModel[];
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue