Skip to content

Commit

Permalink
fix(test): fix imports for jsdocs example verification (#2281)
Browse files Browse the repository at this point in the history
  • Loading branch information
ST-DDT committed Jul 29, 2023
1 parent a4631db commit 2fe1308
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion test/scripts/apidoc/verify-jsdoc-tags.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,9 @@ describe('verify JSDoc tags', () => {
mkdirSync(dir, { recursive: true });

const path = resolvePathToMethodFile(moduleName, methodName);
const imports = [...new Set(examples.match(/faker[^\.]*(?=\.)/g))];
const imports = [
...new Set(examples.match(/(?<!\.)faker[^\.]*(?=\.)/g)),
];
writeFileSync(
path,
`import { ${imports.join(
Expand Down

0 comments on commit 2fe1308

Please sign in to comment.