mirror of
https://github.com/CommunitySolidServer/CommunitySolidServer.git
synced 2024-10-03 14:55:10 +00:00

This replaces the recursive backend calls to find the storage by a new class that is aware what the storage URLs look like.
11 lines
425 B
TypeScript
11 lines
425 B
TypeScript
import { RootStorageLocationStrategy } from '../../../../src/server/description/RootStorageLocationStrategy';
|
|
|
|
describe('A RootStorageLocationStrategy', (): void => {
|
|
const baseUrl = 'http://example.com/';
|
|
const strategy = new RootStorageLocationStrategy(baseUrl);
|
|
|
|
it('returns the base URL.', async(): Promise<void> => {
|
|
await expect(strategy.getStorageIdentifier()).resolves.toEqual({ path: baseUrl });
|
|
});
|
|
});
|