(specifiers: string[])
| 325 | } |
| 326 | |
| 327 | async function assertDocs(specifiers: string[]) { |
| 328 | const docs = await doc(specifiers, { resolve }); |
| 329 | for (const d of Object.values(docs).flat()) { |
| 330 | if (d.jsDoc === undefined || d.declarationKind !== "export") continue; |
| 331 | |
| 332 | const document = d as DocNodeWithJsDoc<DocNode>; |
| 333 | assertHasDeprecationDesc(document); |
| 334 | switch (document.kind) { |
| 335 | case "moduleDoc": { |
| 336 | if (document.location.filename.endsWith("/mod.ts")) { |
| 337 | assertModuleDoc(document); |
| 338 | } |
| 339 | break; |
| 340 | } |
| 341 | case "function": { |
| 342 | assertFunctionDocs(document); |
| 343 | break; |
| 344 | } |
| 345 | case "class": { |
| 346 | assertClassDocs(document); |
| 347 | break; |
| 348 | } |
| 349 | } |
| 350 | } |
| 351 | } |
| 352 | |
| 353 | export async function checkDocs(specifiers: string[]) { |
| 354 | const { success, stderr } = await new Deno.Command(Deno.execPath(), { |
no test coverage detected