openapi-jsonrpc-jsdoc 1.0.3 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (35) hide show
  1. package/README.md +139 -19
  2. package/index.js +5 -2
  3. package/out/fonts/OpenSans-Bold-webfont.eot +0 -0
  4. package/out/fonts/OpenSans-Bold-webfont.svg +1830 -0
  5. package/out/fonts/OpenSans-Bold-webfont.woff +0 -0
  6. package/out/fonts/OpenSans-BoldItalic-webfont.eot +0 -0
  7. package/out/fonts/OpenSans-BoldItalic-webfont.svg +1830 -0
  8. package/out/fonts/OpenSans-BoldItalic-webfont.woff +0 -0
  9. package/out/fonts/OpenSans-Italic-webfont.eot +0 -0
  10. package/out/fonts/OpenSans-Italic-webfont.svg +1830 -0
  11. package/out/fonts/OpenSans-Italic-webfont.woff +0 -0
  12. package/out/fonts/OpenSans-Light-webfont.eot +0 -0
  13. package/out/fonts/OpenSans-Light-webfont.svg +1831 -0
  14. package/out/fonts/OpenSans-Light-webfont.woff +0 -0
  15. package/out/fonts/OpenSans-LightItalic-webfont.eot +0 -0
  16. package/out/fonts/OpenSans-LightItalic-webfont.svg +1835 -0
  17. package/out/fonts/OpenSans-LightItalic-webfont.woff +0 -0
  18. package/out/fonts/OpenSans-Regular-webfont.eot +0 -0
  19. package/out/fonts/OpenSans-Regular-webfont.svg +1831 -0
  20. package/out/fonts/OpenSans-Regular-webfont.woff +0 -0
  21. package/out/index.html +65 -0
  22. package/out/scripts/linenumber.js +25 -0
  23. package/out/scripts/prettify/Apache-License-2.0.txt +202 -0
  24. package/out/scripts/prettify/lang-css.js +2 -0
  25. package/out/scripts/prettify/prettify.js +28 -0
  26. package/out/styles/jsdoc-default.css +358 -0
  27. package/out/styles/prettify-jsdoc.css +111 -0
  28. package/out/styles/prettify-tomorrow.css +132 -0
  29. package/out/v1.js.html +58 -0
  30. package/package.json +19 -13
  31. package/.github/workflows/nodejs.yml +0 -25
  32. package/.github/workflows/npmpublish.yml +0 -45
  33. package/test/api/v1.js +0 -8
  34. package/test/api/v2.js +0 -8
  35. package/test/index.test.js +0 -39
@@ -1,25 +0,0 @@
1
- name: Node CI
2
-
3
- on: [push]
4
-
5
- jobs:
6
- build:
7
-
8
- runs-on: ubuntu-latest
9
-
10
- strategy:
11
- matrix:
12
- node-version: [12.x]
13
-
14
- steps:
15
- - uses: actions/checkout@v1
16
- - name: Use Node.js ${{ matrix.node-version }}
17
- uses: actions/setup-node@v1
18
- with:
19
- node-version: ${{ matrix.node-version }}
20
- - name: npm install and test
21
- run: |
22
- npm i
23
- npm test
24
- env:
25
- CI: true
@@ -1,45 +0,0 @@
1
- name: Node.js Package
2
-
3
- on:
4
- release:
5
- types: [created]
6
-
7
- jobs:
8
- build:
9
- runs-on: ubuntu-latest
10
- steps:
11
- - uses: actions/checkout@v1
12
- - uses: actions/setup-node@v1
13
- with:
14
- node-version: 12
15
- - run: npm ci
16
- - run: npm test
17
-
18
- publish-npm:
19
- needs: build
20
- runs-on: ubuntu-latest
21
- steps:
22
- - uses: actions/checkout@v1
23
- - uses: actions/setup-node@v1
24
- with:
25
- node-version: 12
26
- registry-url: https://registry.npmjs.org/
27
- - run: npm i
28
- - run: npm publish
29
- env:
30
- NODE_AUTH_TOKEN: ${{secrets.npm_token}}
31
-
32
- publish-gpr:
33
- needs: build
34
- runs-on: ubuntu-latest
35
- steps:
36
- - uses: actions/checkout@v1
37
- - uses: actions/setup-node@v1
38
- with:
39
- node-version: 12
40
- registry-url: https://npm.pkg.github.com/
41
- scope: '@qertis'
42
- - run: npm ci
43
- - run: npm publish
44
- env:
45
- NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
package/test/api/v1.js DELETED
@@ -1,8 +0,0 @@
1
- /**
2
- * @description Название API
3
- * @param {object} parameters - params
4
- * @param {string} parameters.id - id
5
- */
6
- module.exports = (parameters) => {
7
- return parameters.id;
8
- };
package/test/api/v2.js DELETED
@@ -1,8 +0,0 @@
1
- /**
2
- * @deprecated
3
- * @description Название API 2
4
- * @return {null}
5
- */
6
- module.exports = () => {
7
- return null;
8
- };
@@ -1,39 +0,0 @@
1
- const test = require('ava');
2
- const openapiJSONRpcJSDoc = require('../index');
3
-
4
- test.before(async t => {
5
- t.context.data = await openapiJSONRpcJSDoc({
6
- api: '/api/',
7
- securitySchemes: {
8
- BasicAuth: {
9
- type: 'http',
10
- scheme: 'digest',
11
- },
12
- },
13
- servers: [
14
- {
15
- url: '0.0.0.0:8080',
16
- },
17
- ],
18
- packageUrl: './package.json',
19
- files: './test/api/*.js',
20
- });
21
- });
22
-
23
- test('t1', t => {
24
- const data = t.context.data;
25
- const v1Test = data.paths['/api/v1'];
26
- t.false(v1Test.post.deprecated);
27
- t.is(typeof v1Test.post.description, 'string');
28
- t.true(Array.isArray(v1Test.post.tags));
29
- t.true(Array.isArray(v1Test.post.parameters));
30
- const v1RequestBodySchema = v1Test.post.requestBody.content['application/json'].schema;
31
- t.is(v1RequestBodySchema.type, 'object');
32
- t.true(v1RequestBodySchema.required.includes('id'));
33
- });
34
-
35
- test('t2', t => {
36
- const data = t.context.data;
37
- const v2Test = data.paths['/api/v2'];
38
- t.true(v2Test.post.deprecated);
39
- });