fix: log schema names correctly, do not log unmatched files
This commit is contained in:
parent
d5e321039c
commit
02ccffda6b
|
@ -132,7 +132,7 @@ export async function loadRulePaths(paths: Array<string>, ctx: VisitorContext):
|
|||
.filter((name) => name[0] !== '.')
|
||||
.filter((name) => match.match(name));
|
||||
|
||||
ctx.logger.debug({ allFiles, files }, 'path matched files');
|
||||
ctx.logger.debug({ files }, 'path matched rule files');
|
||||
|
||||
const pathRules = await loadRuleFiles(files, ctx);
|
||||
rules.push(...pathRules);
|
||||
|
|
|
@ -51,8 +51,8 @@ export class VisitorContext implements VisitorContextOptions, VisitorResult {
|
|||
|
||||
public addSchema(name: string, schema: any): void {
|
||||
this.logger.debug({
|
||||
name,
|
||||
schema,
|
||||
schemaName: name,
|
||||
}, 'adding ajv schema');
|
||||
|
||||
this.ajv.addSchema({
|
||||
|
|
|
@ -96,7 +96,6 @@ describeLeaks('load rule path helper', async () => {
|
|||
});
|
||||
|
||||
itLeaks('should recursively load rule files', async () => {
|
||||
|
||||
mockFS({
|
||||
test: {
|
||||
'bar-dir': {
|
||||
|
|
Loading…
Reference in New Issue