0.4.1 • Published 5 years ago

prismy-test-server v0.4.1

Weekly downloads
11
License
MIT
Repository
github
Last release
5 years ago

prismy-test-server

:telescope: E2E test tool for prismy.

Build Status codecov NPM download Language grade: JavaScript

import { testServer } from 'prismy-test-server'
import got from 'got'

describe('testServer', () => {
  it('tests server', async () => {
    class Handler {
      execute() {
        return 'Hello, World!'
      }
    }

    await testServer(Handler, async url => {
      const result = await got(url)

      expect(result).toMatchObject({
        body: 'Hello, World!'
      })
    })
  })
})

License

MIT

0.4.1

5 years ago

0.4.0

5 years ago

0.3.0

5 years ago

0.2.0

5 years ago

0.1.1

5 years ago

0.1.0

5 years ago