2.3.0 • Published 4 years ago

@midwayjs/hooks-testing-library v2.3.0

Weekly downloads
66
License
MIT
Repository
github
Last release
4 years ago

@midwayjs/hooks-testing-library

Usage

import { createApp, HooksApplication } from '@midwayjs/hooks-testing-library';
import api, { get, post } from './api.ts';

describe('test new features', () => {
  let app: HooksApplication;
  beforeAll(async () => {
    app = await createApp();
  });

  afterAll(async () => {
    await app.close();
  });

  it('runFunction', async () => {
    expect(await app.runFunction(api)).toMatchInlineSnapshot();
    expect(await app.runFunction(post, 'Jake')).toMatchInlineSnapshot();
  });

  it('request', async () => {
    const response = await app.request(get).expect(200);
    expect(response.body).toMatchInlineSnapshot();
  });
});
3.0.0-alpha.0

4 years ago

2.4.0-alpha.0

4 years ago

2.3.0

4 years ago

2.3.0-next.1

4 years ago

2.3.0-next.0

4 years ago

2.2.5-next.7

4 years ago

2.2.5-next.6

4 years ago

2.2.5-next.5

4 years ago

2.2.5-next.4

4 years ago

2.2.5-next.3

4 years ago

2.2.5-next.2

4 years ago

2.2.5-next.1

4 years ago

2.2.5-next.0

4 years ago

2.2.4

4 years ago

2.2.2

4 years ago

2.2.1

4 years ago

2.2.0

4 years ago

2.2.0-next.11

4 years ago

2.2.0-next.12

4 years ago

2.2.0-next.10

4 years ago

2.2.0-next.9

4 years ago

2.2.0-next.8

4 years ago

2.2.0-next.7

4 years ago

2.2.0-next.6

4 years ago

2.2.0-next.5

4 years ago

2.2.0-next.4

4 years ago

2.2.0-next.3

4 years ago

2.2.0-next.2

4 years ago

2.2.0-next.1

4 years ago

2.2.0-next.0

4 years ago

2.1.0

4 years ago

2.1.0-next.7

4 years ago

2.1.0-next.6

4 years ago

2.1.0-next.5

4 years ago

2.1.0-next.2

4 years ago

2.1.0-next.4

4 years ago

2.1.0-next.3

4 years ago

2.1.0-next.1

4 years ago

2.1.0-next.0

4 years ago

2.0.1-next.0

4 years ago

2.0.0

4 years ago

2.0.0-next.5

4 years ago

2.0.0-next.4

4 years ago

2.0.0-next.2

4 years ago

2.0.0-next.1

4 years ago