Molid - A mock solid server for local testing

I just released version 0.2.0 :tada: with some brand new features and a shiny and extended documentation.

Molid 0.2.0 allows you to automatically start and stop instances, which makes it great for integration testing :test_tube:

Try the givenMolid-block for Jest:

import { givenMolid } from 'molid/lib/molid-jest';
import { loadProfile } from './your-code';

describe('using the givenMolid function', () => {
    givenMolid('with a profile of a person called John', molid => {
        it('successfully fetches the profile document', async () => {
            const webId = molid.uri('/profile/card#me');
            const profile = await loadProfile(webId);
            expect(profile.name).toEqual('John');
        });
    });
});

:open_book: Read the full docs:

https://molid.readthedocs.io/

6 Likes