aboutsummaryrefslogtreecommitdiffstats
path: root/packages/sra-api/test/api_test.ts
blob: 47353ca80ab7a984dfeb92f59e1514f2a60a4e1e (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
import * as chai from 'chai';
import * as dirtyChai from 'dirty-chai';
import { validate } from 'openapi-schema-validation';

import { api } from '../src/index';

chai.config.includeStack = true;
chai.use(dirtyChai);

describe('SRA OpenAPI Schema', () => {
    it('should be a valid OpenAPI schema', () => {
        const result = validate(api, 3);
        chai.expect(result.errors).to.have.length(0);
    });
});