@graphql-inspector/coverage-command 0.0.0-canary.6f0f272 → 0.0.0-canary.9e26f61
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.
- package/index.d.ts +8 -0
- package/index.js +119 -0
- package/{index.esm.js → index.mjs} +47 -49
- package/package.json +17 -7
- package/index.cjs.js +0 -119
- package/index.cjs.js.map +0 -1
- package/index.esm.js.map +0 -1
package/index.d.ts
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
import { GlobalArgs, CommandFactory } from '@graphql-inspector/commands';
|
|
2
|
+
import { Source as DocumentSource } from '@graphql-tools/utils';
|
|
3
|
+
import { GraphQLSchema } from 'graphql';
|
|
2
4
|
export { CommandFactory };
|
|
5
|
+
export declare function handler({ schema, documents, silent, writePath, }: {
|
|
6
|
+
schema: GraphQLSchema;
|
|
7
|
+
documents: DocumentSource[];
|
|
8
|
+
silent?: boolean;
|
|
9
|
+
writePath?: string;
|
|
10
|
+
}): void;
|
|
3
11
|
declare const _default: CommandFactory<{}, {
|
|
4
12
|
schema: string;
|
|
5
13
|
documents: string;
|
package/index.js
ADDED
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const tslib = require('tslib');
|
|
6
|
+
const commands = require('@graphql-inspector/commands');
|
|
7
|
+
const logger = require('@graphql-inspector/logger');
|
|
8
|
+
const core = require('@graphql-inspector/core');
|
|
9
|
+
const graphql = require('graphql');
|
|
10
|
+
const path = require('path');
|
|
11
|
+
const fs = require('fs');
|
|
12
|
+
|
|
13
|
+
function handler({ schema, documents, silent, writePath, }) {
|
|
14
|
+
const shouldWrite = typeof writePath !== 'undefined';
|
|
15
|
+
const coverage = core.coverage(schema, documents.map(doc => new graphql.Source(graphql.print(doc.document), doc.location)));
|
|
16
|
+
if (silent !== true) {
|
|
17
|
+
renderCoverage(coverage);
|
|
18
|
+
}
|
|
19
|
+
if (shouldWrite) {
|
|
20
|
+
if (typeof writePath !== 'string') {
|
|
21
|
+
throw new Error(`--write is not valid file path: ${writePath}`);
|
|
22
|
+
}
|
|
23
|
+
const absPath = commands.ensureAbsolute(writePath);
|
|
24
|
+
const ext = path.extname(absPath).replace('.', '').toLocaleLowerCase();
|
|
25
|
+
let output = undefined;
|
|
26
|
+
if (ext === 'json') {
|
|
27
|
+
output = outputJSON(coverage);
|
|
28
|
+
}
|
|
29
|
+
if (output) {
|
|
30
|
+
fs.writeFileSync(absPath, output, {
|
|
31
|
+
encoding: 'utf-8',
|
|
32
|
+
});
|
|
33
|
+
logger.Logger.success(`Available at ${absPath}\n`);
|
|
34
|
+
}
|
|
35
|
+
else {
|
|
36
|
+
throw new Error(`Extension ${ext} is not supported`);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
const index = commands.createCommand(api => {
|
|
41
|
+
const { loaders } = api;
|
|
42
|
+
return {
|
|
43
|
+
command: 'coverage <documents> <schema>',
|
|
44
|
+
describe: 'Schema coverage based on documents',
|
|
45
|
+
builder(yargs) {
|
|
46
|
+
return yargs
|
|
47
|
+
.positional('schema', {
|
|
48
|
+
describe: 'Point to a schema',
|
|
49
|
+
type: 'string',
|
|
50
|
+
demandOption: true,
|
|
51
|
+
})
|
|
52
|
+
.positional('documents', {
|
|
53
|
+
describe: 'Point to documents',
|
|
54
|
+
type: 'string',
|
|
55
|
+
demandOption: true,
|
|
56
|
+
})
|
|
57
|
+
.options({
|
|
58
|
+
w: {
|
|
59
|
+
alias: 'write',
|
|
60
|
+
describe: 'Write a file with coverage stats',
|
|
61
|
+
type: 'string',
|
|
62
|
+
},
|
|
63
|
+
s: {
|
|
64
|
+
alias: 'silent',
|
|
65
|
+
describe: 'Do not render any stats in the terminal',
|
|
66
|
+
type: 'boolean',
|
|
67
|
+
},
|
|
68
|
+
});
|
|
69
|
+
},
|
|
70
|
+
handler(args) {
|
|
71
|
+
var _a;
|
|
72
|
+
return tslib.__awaiter(this, void 0, void 0, function* () {
|
|
73
|
+
const writePath = args.write;
|
|
74
|
+
const silent = args.silent;
|
|
75
|
+
const { headers, token } = commands.parseGlobalArgs(args);
|
|
76
|
+
const apolloFederation = args.federation || false;
|
|
77
|
+
const aws = args.aws || false;
|
|
78
|
+
const method = ((_a = args.method) === null || _a === void 0 ? void 0 : _a.toUpperCase()) || 'POST';
|
|
79
|
+
const schema = yield loaders.loadSchema(args.schema, {
|
|
80
|
+
token,
|
|
81
|
+
headers,
|
|
82
|
+
method,
|
|
83
|
+
}, apolloFederation, aws);
|
|
84
|
+
const documents = yield loaders.loadDocuments(args.documents);
|
|
85
|
+
return handler({ schema, documents, silent, writePath });
|
|
86
|
+
});
|
|
87
|
+
},
|
|
88
|
+
};
|
|
89
|
+
});
|
|
90
|
+
function outputJSON(coverage) {
|
|
91
|
+
return JSON.stringify(coverage, null, 2);
|
|
92
|
+
}
|
|
93
|
+
function renderCoverage(coverage) {
|
|
94
|
+
logger.Logger.info('Schema coverage based on documents:\n');
|
|
95
|
+
for (const typeName in coverage.types) {
|
|
96
|
+
if (coverage.types.hasOwnProperty(typeName)) {
|
|
97
|
+
const typeCoverage = coverage.types[typeName];
|
|
98
|
+
logger.Logger.log([logger.chalk.grey(core.getTypePrefix(typeCoverage.type)), logger.chalk.bold(`${typeName}`), logger.chalk.grey('{')].join(' '));
|
|
99
|
+
for (const childName in typeCoverage.children) {
|
|
100
|
+
if (typeCoverage.children.hasOwnProperty(childName)) {
|
|
101
|
+
const childCoverage = typeCoverage.children[childName];
|
|
102
|
+
if (childCoverage.hits) {
|
|
103
|
+
logger.Logger.log([indent(childName, 2), logger.chalk.italic.grey(`x ${childCoverage.hits}`)].join(' '));
|
|
104
|
+
}
|
|
105
|
+
else {
|
|
106
|
+
logger.Logger.log([logger.chalk.redBright(indent(childName, 2)), logger.chalk.italic.grey('x 0')].join(' '));
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
logger.Logger.log(logger.chalk.grey('}\n'));
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
function indent(line, space) {
|
|
115
|
+
return line.padStart(line.length + space, ' ');
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
exports.default = index;
|
|
119
|
+
exports.handler = handler;
|
|
@@ -6,24 +6,51 @@ import { Source, print } from 'graphql';
|
|
|
6
6
|
import { extname } from 'path';
|
|
7
7
|
import { writeFileSync } from 'fs';
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
const
|
|
9
|
+
function handler({ schema, documents, silent, writePath, }) {
|
|
10
|
+
const shouldWrite = typeof writePath !== 'undefined';
|
|
11
|
+
const coverage$1 = coverage(schema, documents.map(doc => new Source(print(doc.document), doc.location)));
|
|
12
|
+
if (silent !== true) {
|
|
13
|
+
renderCoverage(coverage$1);
|
|
14
|
+
}
|
|
15
|
+
if (shouldWrite) {
|
|
16
|
+
if (typeof writePath !== 'string') {
|
|
17
|
+
throw new Error(`--write is not valid file path: ${writePath}`);
|
|
18
|
+
}
|
|
19
|
+
const absPath = ensureAbsolute(writePath);
|
|
20
|
+
const ext = extname(absPath).replace('.', '').toLocaleLowerCase();
|
|
21
|
+
let output = undefined;
|
|
22
|
+
if (ext === 'json') {
|
|
23
|
+
output = outputJSON(coverage$1);
|
|
24
|
+
}
|
|
25
|
+
if (output) {
|
|
26
|
+
writeFileSync(absPath, output, {
|
|
27
|
+
encoding: 'utf-8',
|
|
28
|
+
});
|
|
29
|
+
Logger.success(`Available at ${absPath}\n`);
|
|
30
|
+
}
|
|
31
|
+
else {
|
|
32
|
+
throw new Error(`Extension ${ext} is not supported`);
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
const index = createCommand(api => {
|
|
37
|
+
const { loaders } = api;
|
|
11
38
|
return {
|
|
12
39
|
command: 'coverage <documents> <schema>',
|
|
13
40
|
describe: 'Schema coverage based on documents',
|
|
14
41
|
builder(yargs) {
|
|
15
42
|
return yargs
|
|
16
|
-
.positional('schema',
|
|
43
|
+
.positional('schema', {
|
|
17
44
|
describe: 'Point to a schema',
|
|
18
45
|
type: 'string',
|
|
19
46
|
demandOption: true,
|
|
20
|
-
})
|
|
21
|
-
.positional('documents',
|
|
47
|
+
})
|
|
48
|
+
.positional('documents', {
|
|
22
49
|
describe: 'Point to documents',
|
|
23
50
|
type: 'string',
|
|
24
51
|
demandOption: true,
|
|
25
|
-
})
|
|
26
|
-
.options(
|
|
52
|
+
})
|
|
53
|
+
.options({
|
|
27
54
|
w: {
|
|
28
55
|
alias: 'write',
|
|
29
56
|
describe: 'Write a file with coverage stats',
|
|
@@ -34,43 +61,24 @@ const index = createCommand((api) => {
|
|
|
34
61
|
describe: 'Do not render any stats in the terminal',
|
|
35
62
|
type: 'boolean',
|
|
36
63
|
},
|
|
37
|
-
})
|
|
64
|
+
});
|
|
38
65
|
},
|
|
39
66
|
handler(args) {
|
|
67
|
+
var _a;
|
|
40
68
|
return __awaiter(this, void 0, void 0, function* () {
|
|
41
|
-
yield interceptArguments(args);
|
|
42
69
|
const writePath = args.write;
|
|
43
|
-
const
|
|
70
|
+
const silent = args.silent;
|
|
44
71
|
const { headers, token } = parseGlobalArgs(args);
|
|
72
|
+
const apolloFederation = args.federation || false;
|
|
73
|
+
const aws = args.aws || false;
|
|
74
|
+
const method = ((_a = args.method) === null || _a === void 0 ? void 0 : _a.toUpperCase()) || 'POST';
|
|
45
75
|
const schema = yield loaders.loadSchema(args.schema, {
|
|
46
76
|
token,
|
|
47
77
|
headers,
|
|
48
|
-
|
|
78
|
+
method,
|
|
79
|
+
}, apolloFederation, aws);
|
|
49
80
|
const documents = yield loaders.loadDocuments(args.documents);
|
|
50
|
-
|
|
51
|
-
if (args.silent !== true) {
|
|
52
|
-
renderCoverage(coverage$1);
|
|
53
|
-
}
|
|
54
|
-
if (shouldWrite) {
|
|
55
|
-
if (typeof writePath !== 'string') {
|
|
56
|
-
throw new Error(`--write is not valid file path: ${writePath}`);
|
|
57
|
-
}
|
|
58
|
-
const absPath = ensureAbsolute(writePath);
|
|
59
|
-
const ext = extname(absPath).replace('.', '').toLocaleLowerCase();
|
|
60
|
-
let output = undefined;
|
|
61
|
-
if (ext === 'json') {
|
|
62
|
-
output = outputJSON(coverage$1);
|
|
63
|
-
}
|
|
64
|
-
if (output) {
|
|
65
|
-
writeFileSync(absPath, output, {
|
|
66
|
-
encoding: 'utf-8',
|
|
67
|
-
});
|
|
68
|
-
Logger.success(`Available at ${absPath}\n`);
|
|
69
|
-
}
|
|
70
|
-
else {
|
|
71
|
-
throw new Error(`Extension ${ext} is not supported`);
|
|
72
|
-
}
|
|
73
|
-
}
|
|
81
|
+
return handler({ schema, documents, silent, writePath });
|
|
74
82
|
});
|
|
75
83
|
},
|
|
76
84
|
};
|
|
@@ -83,25 +91,15 @@ function renderCoverage(coverage) {
|
|
|
83
91
|
for (const typeName in coverage.types) {
|
|
84
92
|
if (coverage.types.hasOwnProperty(typeName)) {
|
|
85
93
|
const typeCoverage = coverage.types[typeName];
|
|
86
|
-
Logger.log([
|
|
87
|
-
chalk.grey(getTypePrefix(typeCoverage.type)),
|
|
88
|
-
chalk.bold(`${typeName}`),
|
|
89
|
-
chalk.grey('{'),
|
|
90
|
-
].join(' '));
|
|
94
|
+
Logger.log([chalk.grey(getTypePrefix(typeCoverage.type)), chalk.bold(`${typeName}`), chalk.grey('{')].join(' '));
|
|
91
95
|
for (const childName in typeCoverage.children) {
|
|
92
96
|
if (typeCoverage.children.hasOwnProperty(childName)) {
|
|
93
97
|
const childCoverage = typeCoverage.children[childName];
|
|
94
98
|
if (childCoverage.hits) {
|
|
95
|
-
Logger.log([
|
|
96
|
-
indent(childName, 2),
|
|
97
|
-
chalk.italic.grey(`x ${childCoverage.hits}`),
|
|
98
|
-
].join(' '));
|
|
99
|
+
Logger.log([indent(childName, 2), chalk.italic.grey(`x ${childCoverage.hits}`)].join(' '));
|
|
99
100
|
}
|
|
100
101
|
else {
|
|
101
|
-
Logger.log([
|
|
102
|
-
chalk.redBright(indent(childName, 2)),
|
|
103
|
-
chalk.italic.grey('x 0'),
|
|
104
|
-
].join(' '));
|
|
102
|
+
Logger.log([chalk.redBright(indent(childName, 2)), chalk.italic.grey('x 0')].join(' '));
|
|
105
103
|
}
|
|
106
104
|
}
|
|
107
105
|
}
|
|
@@ -114,4 +112,4 @@ function indent(line, space) {
|
|
|
114
112
|
}
|
|
115
113
|
|
|
116
114
|
export default index;
|
|
117
|
-
|
|
115
|
+
export { handler };
|
package/package.json
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@graphql-inspector/coverage-command",
|
|
3
|
-
"version": "0.0.0-canary.
|
|
3
|
+
"version": "0.0.0-canary.9e26f61",
|
|
4
4
|
"description": "Schema Coverage in GraphQL Inspector",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"peerDependencies": {
|
|
7
|
-
"graphql": "^0.13.0 || ^14.0.0 || ^15.0.0"
|
|
7
|
+
"graphql": "^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0"
|
|
8
8
|
},
|
|
9
9
|
"dependencies": {
|
|
10
|
-
"@graphql-inspector/commands": "0.0.0-canary.
|
|
11
|
-
"@graphql-inspector/core": "0.0.0-canary.
|
|
12
|
-
"@graphql-inspector/logger": "0.0.0-canary.
|
|
10
|
+
"@graphql-inspector/commands": "0.0.0-canary.9e26f61",
|
|
11
|
+
"@graphql-inspector/core": "0.0.0-canary.9e26f61",
|
|
12
|
+
"@graphql-inspector/logger": "0.0.0-canary.9e26f61",
|
|
13
13
|
"tslib": "^2.0.0"
|
|
14
14
|
},
|
|
15
15
|
"repository": {
|
|
@@ -29,10 +29,20 @@
|
|
|
29
29
|
"url": "https://github.com/kamilkisiela"
|
|
30
30
|
},
|
|
31
31
|
"license": "MIT",
|
|
32
|
-
"main": "index.
|
|
33
|
-
"module": "index.
|
|
32
|
+
"main": "index.js",
|
|
33
|
+
"module": "index.mjs",
|
|
34
34
|
"typings": "index.d.ts",
|
|
35
35
|
"typescript": {
|
|
36
36
|
"definition": "index.d.ts"
|
|
37
|
+
},
|
|
38
|
+
"exports": {
|
|
39
|
+
".": {
|
|
40
|
+
"require": "./index.js",
|
|
41
|
+
"import": "./index.mjs"
|
|
42
|
+
},
|
|
43
|
+
"./*": {
|
|
44
|
+
"require": "./*.js",
|
|
45
|
+
"import": "./*.mjs"
|
|
46
|
+
}
|
|
37
47
|
}
|
|
38
48
|
}
|
package/index.cjs.js
DELETED
|
@@ -1,119 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
const tslib = require('tslib');
|
|
4
|
-
const commands = require('@graphql-inspector/commands');
|
|
5
|
-
const logger = require('@graphql-inspector/logger');
|
|
6
|
-
const core = require('@graphql-inspector/core');
|
|
7
|
-
const graphql = require('graphql');
|
|
8
|
-
const path = require('path');
|
|
9
|
-
const fs = require('fs');
|
|
10
|
-
|
|
11
|
-
const index = commands.createCommand((api) => {
|
|
12
|
-
const { loaders, interceptArguments, interceptPositional, interceptOptions, } = api;
|
|
13
|
-
return {
|
|
14
|
-
command: 'coverage <documents> <schema>',
|
|
15
|
-
describe: 'Schema coverage based on documents',
|
|
16
|
-
builder(yargs) {
|
|
17
|
-
return yargs
|
|
18
|
-
.positional('schema', interceptPositional('schema', {
|
|
19
|
-
describe: 'Point to a schema',
|
|
20
|
-
type: 'string',
|
|
21
|
-
demandOption: true,
|
|
22
|
-
}))
|
|
23
|
-
.positional('documents', interceptPositional('documents', {
|
|
24
|
-
describe: 'Point to documents',
|
|
25
|
-
type: 'string',
|
|
26
|
-
demandOption: true,
|
|
27
|
-
}))
|
|
28
|
-
.options(interceptOptions({
|
|
29
|
-
w: {
|
|
30
|
-
alias: 'write',
|
|
31
|
-
describe: 'Write a file with coverage stats',
|
|
32
|
-
type: 'string',
|
|
33
|
-
},
|
|
34
|
-
s: {
|
|
35
|
-
alias: 'silent',
|
|
36
|
-
describe: 'Do not render any stats in the terminal',
|
|
37
|
-
type: 'boolean',
|
|
38
|
-
},
|
|
39
|
-
}));
|
|
40
|
-
},
|
|
41
|
-
handler(args) {
|
|
42
|
-
return tslib.__awaiter(this, void 0, void 0, function* () {
|
|
43
|
-
yield interceptArguments(args);
|
|
44
|
-
const writePath = args.write;
|
|
45
|
-
const shouldWrite = typeof writePath !== 'undefined';
|
|
46
|
-
const { headers, token } = commands.parseGlobalArgs(args);
|
|
47
|
-
const schema = yield loaders.loadSchema(args.schema, {
|
|
48
|
-
token,
|
|
49
|
-
headers,
|
|
50
|
-
});
|
|
51
|
-
const documents = yield loaders.loadDocuments(args.documents);
|
|
52
|
-
const coverage = core.coverage(schema, documents.map((doc) => new graphql.Source(graphql.print(doc.document), doc.location)));
|
|
53
|
-
if (args.silent !== true) {
|
|
54
|
-
renderCoverage(coverage);
|
|
55
|
-
}
|
|
56
|
-
if (shouldWrite) {
|
|
57
|
-
if (typeof writePath !== 'string') {
|
|
58
|
-
throw new Error(`--write is not valid file path: ${writePath}`);
|
|
59
|
-
}
|
|
60
|
-
const absPath = commands.ensureAbsolute(writePath);
|
|
61
|
-
const ext = path.extname(absPath).replace('.', '').toLocaleLowerCase();
|
|
62
|
-
let output = undefined;
|
|
63
|
-
if (ext === 'json') {
|
|
64
|
-
output = outputJSON(coverage);
|
|
65
|
-
}
|
|
66
|
-
if (output) {
|
|
67
|
-
fs.writeFileSync(absPath, output, {
|
|
68
|
-
encoding: 'utf-8',
|
|
69
|
-
});
|
|
70
|
-
logger.Logger.success(`Available at ${absPath}\n`);
|
|
71
|
-
}
|
|
72
|
-
else {
|
|
73
|
-
throw new Error(`Extension ${ext} is not supported`);
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
});
|
|
77
|
-
},
|
|
78
|
-
};
|
|
79
|
-
});
|
|
80
|
-
function outputJSON(coverage) {
|
|
81
|
-
return JSON.stringify(coverage, null, 2);
|
|
82
|
-
}
|
|
83
|
-
function renderCoverage(coverage) {
|
|
84
|
-
logger.Logger.info('Schema coverage based on documents:\n');
|
|
85
|
-
for (const typeName in coverage.types) {
|
|
86
|
-
if (coverage.types.hasOwnProperty(typeName)) {
|
|
87
|
-
const typeCoverage = coverage.types[typeName];
|
|
88
|
-
logger.Logger.log([
|
|
89
|
-
logger.chalk.grey(core.getTypePrefix(typeCoverage.type)),
|
|
90
|
-
logger.chalk.bold(`${typeName}`),
|
|
91
|
-
logger.chalk.grey('{'),
|
|
92
|
-
].join(' '));
|
|
93
|
-
for (const childName in typeCoverage.children) {
|
|
94
|
-
if (typeCoverage.children.hasOwnProperty(childName)) {
|
|
95
|
-
const childCoverage = typeCoverage.children[childName];
|
|
96
|
-
if (childCoverage.hits) {
|
|
97
|
-
logger.Logger.log([
|
|
98
|
-
indent(childName, 2),
|
|
99
|
-
logger.chalk.italic.grey(`x ${childCoverage.hits}`),
|
|
100
|
-
].join(' '));
|
|
101
|
-
}
|
|
102
|
-
else {
|
|
103
|
-
logger.Logger.log([
|
|
104
|
-
logger.chalk.redBright(indent(childName, 2)),
|
|
105
|
-
logger.chalk.italic.grey('x 0'),
|
|
106
|
-
].join(' '));
|
|
107
|
-
}
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
logger.Logger.log(logger.chalk.grey('}\n'));
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
}
|
|
114
|
-
function indent(line, space) {
|
|
115
|
-
return line.padStart(line.length + space, ' ');
|
|
116
|
-
}
|
|
117
|
-
|
|
118
|
-
module.exports = index;
|
|
119
|
-
//# sourceMappingURL=index.cjs.js.map
|
package/index.cjs.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs.js","sources":["../../dist/commands/coverage/src/index.js"],"sourcesContent":["import { __awaiter } from \"tslib\";\nimport { createCommand, ensureAbsolute, parseGlobalArgs, } from '@graphql-inspector/commands';\nimport { Logger, chalk } from '@graphql-inspector/logger';\nimport { coverage as calculateCoverage, getTypePrefix, } from '@graphql-inspector/core';\nimport { Source, print } from 'graphql';\nimport { extname } from 'path';\nimport { writeFileSync } from 'fs';\nexport default createCommand((api) => {\n const { loaders, interceptArguments, interceptPositional, interceptOptions, } = api;\n return {\n command: 'coverage <documents> <schema>',\n describe: 'Schema coverage based on documents',\n builder(yargs) {\n return yargs\n .positional('schema', interceptPositional('schema', {\n describe: 'Point to a schema',\n type: 'string',\n demandOption: true,\n }))\n .positional('documents', interceptPositional('documents', {\n describe: 'Point to documents',\n type: 'string',\n demandOption: true,\n }))\n .options(interceptOptions({\n w: {\n alias: 'write',\n describe: 'Write a file with coverage stats',\n type: 'string',\n },\n s: {\n alias: 'silent',\n describe: 'Do not render any stats in the terminal',\n type: 'boolean',\n },\n }));\n },\n handler(args) {\n return __awaiter(this, void 0, void 0, function* () {\n yield interceptArguments(args);\n const writePath = args.write;\n const shouldWrite = typeof writePath !== 'undefined';\n const { headers, token } = parseGlobalArgs(args);\n const schema = yield loaders.loadSchema(args.schema, {\n token,\n headers,\n });\n const documents = yield loaders.loadDocuments(args.documents);\n const coverage = calculateCoverage(schema, documents.map((doc) => new Source(print(doc.document), doc.location)));\n if (args.silent !== true) {\n renderCoverage(coverage);\n }\n if (shouldWrite) {\n if (typeof writePath !== 'string') {\n throw new Error(`--write is not valid file path: ${writePath}`);\n }\n const absPath = ensureAbsolute(writePath);\n const ext = extname(absPath).replace('.', '').toLocaleLowerCase();\n let output = undefined;\n if (ext === 'json') {\n output = outputJSON(coverage);\n }\n if (output) {\n writeFileSync(absPath, output, {\n encoding: 'utf-8',\n });\n Logger.success(`Available at ${absPath}\\n`);\n }\n else {\n throw new Error(`Extension ${ext} is not supported`);\n }\n }\n });\n },\n };\n});\nfunction outputJSON(coverage) {\n return JSON.stringify(coverage, null, 2);\n}\nfunction renderCoverage(coverage) {\n Logger.info('Schema coverage based on documents:\\n');\n for (const typeName in coverage.types) {\n if (coverage.types.hasOwnProperty(typeName)) {\n const typeCoverage = coverage.types[typeName];\n Logger.log([\n chalk.grey(getTypePrefix(typeCoverage.type)),\n chalk.bold(`${typeName}`),\n chalk.grey('{'),\n ].join(' '));\n for (const childName in typeCoverage.children) {\n if (typeCoverage.children.hasOwnProperty(childName)) {\n const childCoverage = typeCoverage.children[childName];\n if (childCoverage.hits) {\n Logger.log([\n indent(childName, 2),\n chalk.italic.grey(`x ${childCoverage.hits}`),\n ].join(' '));\n }\n else {\n Logger.log([\n chalk.redBright(indent(childName, 2)),\n chalk.italic.grey('x 0'),\n ].join(' '));\n }\n }\n }\n Logger.log(chalk.grey('}\\n'));\n }\n }\n}\nfunction indent(line, space) {\n return line.padStart(line.length + space, ' ');\n}\n//# sourceMappingURL=index.js.map"],"names":["createCommand","__awaiter","parseGlobalArgs","calculateCoverage","Source","print","ensureAbsolute","extname","writeFileSync","Logger","chalk","getTypePrefix"],"mappings":";;;;;;;;;;AAOA,cAAeA,sBAAa,CAAC,CAAC,GAAG,KAAK;AACtC,IAAI,MAAM,EAAE,OAAO,EAAE,kBAAkB,EAAE,mBAAmB,EAAE,gBAAgB,GAAG,GAAG,GAAG,CAAC;AACxF,IAAI,OAAO;AACX,QAAQ,OAAO,EAAE,+BAA+B;AAChD,QAAQ,QAAQ,EAAE,oCAAoC;AACtD,QAAQ,OAAO,CAAC,KAAK,EAAE;AACvB,YAAY,OAAO,KAAK;AACxB,iBAAiB,UAAU,CAAC,QAAQ,EAAE,mBAAmB,CAAC,QAAQ,EAAE;AACpE,gBAAgB,QAAQ,EAAE,mBAAmB;AAC7C,gBAAgB,IAAI,EAAE,QAAQ;AAC9B,gBAAgB,YAAY,EAAE,IAAI;AAClC,aAAa,CAAC,CAAC;AACf,iBAAiB,UAAU,CAAC,WAAW,EAAE,mBAAmB,CAAC,WAAW,EAAE;AAC1E,gBAAgB,QAAQ,EAAE,oBAAoB;AAC9C,gBAAgB,IAAI,EAAE,QAAQ;AAC9B,gBAAgB,YAAY,EAAE,IAAI;AAClC,aAAa,CAAC,CAAC;AACf,iB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,SAAS,CAAC,MAAM,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC;AACjE,4BAA4BA,YAAK,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;AACpD,yBAAyB,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC;AACrC,qBAAqB;AACrB,iBAAiB;AACjB,aAAa;AACb,YAAYD,aAAM,CAAC,GAAG,CAACC,YAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;AAC1C,SAAS;AACT,KAAK;AACL,CAAC;AACD,SAAS,MAAM,CAAC,IAAI,EAAE,KAAK,EAAE;AAC7B,IAAI,OAAO,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,MAAM,GAAG,KAAK,EAAE,GAAG,CAAC,CAAC;AACnD;;;;"}
|
package/index.esm.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.esm.js","sources":["../../dist/commands/coverage/src/index.js"],"sourcesContent":["import { __awaiter } from \"tslib\";\nimport { createCommand, ensureAbsolute, parseGlobalArgs, } from '@graphql-inspector/commands';\nimport { Logger, chalk } from '@graphql-inspector/logger';\nimport { coverage as calculateCoverage, getTypePrefix, } from '@graphql-inspector/core';\nimport { Source, print } from 'graphql';\nimport { extname } from 'path';\nimport { writeFileSync } from 'fs';\nexport default createCommand((api) => {\n const { loaders, interceptArguments, interceptPositional, interceptOptions, } = api;\n return {\n command: 'coverage <documents> <schema>',\n describe: 'Schema coverage based on documents',\n builder(yargs) {\n return yargs\n .positional('schema', interceptPositional('schema', {\n describe: 'Point to a schema',\n type: 'string',\n demandOption: true,\n }))\n .positional('documents', interceptPositional('documents', {\n describe: 'Point to documents',\n type: 'string',\n demandOption: true,\n }))\n .options(interceptOptions({\n w: {\n alias: 'write',\n describe: 'Write a file with coverage stats',\n type: 'string',\n },\n s: {\n alias: 'silent',\n describe: 'Do not render any stats in the terminal',\n type: 'boolean',\n },\n }));\n },\n handler(args) {\n return __awaiter(this, void 0, void 0, function* () {\n yield interceptArguments(args);\n const writePath = args.write;\n const shouldWrite = typeof writePath !== 'undefined';\n const { headers, token } = parseGlobalArgs(args);\n const schema = yield loaders.loadSchema(args.schema, {\n token,\n headers,\n });\n const documents = yield loaders.loadDocuments(args.documents);\n const coverage = calculateCoverage(schema, documents.map((doc) => new Source(print(doc.document), doc.location)));\n if (args.silent !== true) {\n renderCoverage(coverage);\n }\n if (shouldWrite) {\n if (typeof writePath !== 'string') {\n throw new Error(`--write is not valid file path: ${writePath}`);\n }\n const absPath = ensureAbsolute(writePath);\n const ext = extname(absPath).replace('.', '').toLocaleLowerCase();\n let output = undefined;\n if (ext === 'json') {\n output = outputJSON(coverage);\n }\n if (output) {\n writeFileSync(absPath, output, {\n encoding: 'utf-8',\n });\n Logger.success(`Available at ${absPath}\\n`);\n }\n else {\n throw new Error(`Extension ${ext} is not supported`);\n }\n }\n });\n },\n };\n});\nfunction outputJSON(coverage) {\n return JSON.stringify(coverage, null, 2);\n}\nfunction renderCoverage(coverage) {\n Logger.info('Schema coverage based on documents:\\n');\n for (const typeName in coverage.types) {\n if (coverage.types.hasOwnProperty(typeName)) {\n const typeCoverage = coverage.types[typeName];\n Logger.log([\n chalk.grey(getTypePrefix(typeCoverage.type)),\n chalk.bold(`${typeName}`),\n chalk.grey('{'),\n ].join(' '));\n for (const childName in typeCoverage.children) {\n if (typeCoverage.children.hasOwnProperty(childName)) {\n const childCoverage = typeCoverage.children[childName];\n if (childCoverage.hits) {\n Logger.log([\n indent(childName, 2),\n chalk.italic.grey(`x ${childCoverage.hits}`),\n ].join(' '));\n }\n else {\n Logger.log([\n chalk.redBright(indent(childName, 2)),\n chalk.italic.grey('x 0'),\n ].join(' '));\n }\n }\n }\n Logger.log(chalk.grey('}\\n'));\n }\n }\n}\nfunction indent(line, space) {\n return line.padStart(line.length + space, ' ');\n}\n//# sourceMappingURL=index.js.map"],"names":["coverage","calculateCoverage"],"mappings":";;;;;;;;AAOA,cAAe,aAAa,CAAC,CA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