1
1
exports[`Docs > allows custom file inputs 1`] = `
2
2
{
3
3
"logs": {
4
- "stdout": "Copied typedoc.config.ts\\nInstalling
[email protected] [email protected] .
5 ...\\n> npx md-code --check something-else.md\\ndocs finished.",
4
+ "stdout": "Copied typedoc.config.ts\\nInstalling
[email protected] [email protected] .
6 ...\\n> npx md-code --check something-else.md\\ndocs finished.",
5
5
"stderr": "No markdown files given to insert code into."
6
6
},
7
7
"cwd": "packages/docs/test-files/valid-docs",
8
8
"contentsDiff": {
9
- "package.json": "{\\n \\"type\\": \\"module\\",\\n \\"devDependencies\\": {\\n \\"markdown-code-example-inserter\\": \\"^3.0.3\\",\\n \\"typedoc\\": \\"^0.27.5 \\"\\n }\\n}\\n",
9
+ "package.json": "{\\n \\"type\\": \\"module\\",\\n \\"devDependencies\\": {\\n \\"markdown-code-example-inserter\\": \\"^3.0.3\\",\\n \\"typedoc\\": \\"^0.27.6 \\"\\n }\\n}\\n",
10
10
"configs": {
11
11
"typedoc.config.ts": "import {baseTypedocConfig} from '@virmator/docs/configs/typedoc.config.base';\\nimport {join, resolve} from 'node:path';\\nimport type {TypeDocOptions} from 'typedoc';\\n\\nconst repoRoot = resolve(import.meta.dirname, '..');\\nconst indexTsFile = join(repoRoot, 'src', 'index.ts');\\n\\nexport const typeDocConfig: Partial<TypeDocOptions> = {\\n ...baseTypedocConfig,\\n out: join(repoRoot, 'dist-docs'),\\n entryPoints: [\\n indexTsFile,\\n ],\\n intentionallyNotExported: [],\\n defaultCategory: 'MISSING CATEGORY',\\n categoryOrder: [\\n 'Main',\\n 'Internal',\\n ],\\n};\\n"
12
12
}
@@ -17,12 +17,12 @@ exports[`Docs > allows custom file inputs 1`] = `
17
17
exports[`Docs > does not error on missing markdown files 1`] = `
18
18
{
19
19
"logs": {
20
- "stdout": "Copied typedoc.config.ts\\nInstalling
[email protected] [email protected] .
5 ...\\n> npx md-code 'README.md'\\ndocs finished.",
20
+ "stdout": "Copied typedoc.config.ts\\nInstalling
[email protected] [email protected] .
6 ...\\n> npx md-code 'README.md'\\ndocs finished.",
21
21
"stderr": "No markdown files given to insert code into."
22
22
},
23
23
"cwd": "packages/docs/test-files/mono-repo/packages/c",
24
24
"contentsDiff": {
25
- "package.json": "{\\n \\"name\\": \\"c\\",\\n \\"type\\": \\"module\\",\\n \\"devDependencies\\": {\\n \\"markdown-code-example-inserter\\": \\"^3.0.3\\",\\n \\"typedoc\\": \\"^0.27.5 \\"\\n }\\n}\\n",
25
+ "package.json": "{\\n \\"name\\": \\"c\\",\\n \\"type\\": \\"module\\",\\n \\"devDependencies\\": {\\n \\"markdown-code-example-inserter\\": \\"^3.0.3\\",\\n \\"typedoc\\": \\"^0.27.6 \\"\\n }\\n}\\n",
26
26
"configs": {
27
27
"typedoc.config.ts": "import {baseTypedocConfig} from '@virmator/docs/configs/typedoc.config.base';\\nimport {join, resolve} from 'node:path';\\nimport type {TypeDocOptions} from 'typedoc';\\n\\nconst repoRoot = resolve(import.meta.dirname, '..');\\nconst indexTsFile = join(repoRoot, 'src', 'index.ts');\\n\\nexport const typeDocConfig: Partial<TypeDocOptions> = {\\n ...baseTypedocConfig,\\n out: join(repoRoot, 'dist-docs'),\\n entryPoints: [\\n indexTsFile,\\n ],\\n intentionallyNotExported: [],\\n defaultCategory: 'MISSING CATEGORY',\\n categoryOrder: [\\n 'Main',\\n 'Internal',\\n ],\\n};\\n"
28
28
}
@@ -33,12 +33,12 @@ exports[`Docs > does not error on missing markdown files 1`] = `
33
33
exports[`Docs > fails typedoc check 1`] = `
34
34
{
35
35
"logs": {
36
- "stdout": "Copied typedoc.config.ts\\nInstalling
[email protected] [email protected] .
5 ...\\n> npx md-code --check 'README.md'",
36
+ "stdout": "Copied typedoc.config.ts\\nInstalling
[email protected] [email protected] .
6 ...\\n> npx md-code --check 'README.md'",
37
37
"stderr": "No markdown files given to insert code into.\\ndocs failed."
38
38
},
39
39
"cwd": "packages/docs/test-files/invalid-typedoc",
40
40
"contentsDiff": {
41
- "package.json": "{\\n \\"type\\": \\"module\\",\\n \\"devDependencies\\": {\\n \\"markdown-code-example-inserter\\": \\"^3.0.3\\",\\n \\"typedoc\\": \\"^0.27.5 \\"\\n }\\n}\\n",
41
+ "package.json": "{\\n \\"type\\": \\"module\\",\\n \\"devDependencies\\": {\\n \\"markdown-code-example-inserter\\": \\"^3.0.3\\",\\n \\"typedoc\\": \\"^0.27.6 \\"\\n }\\n}\\n",
42
42
"configs": {
43
43
"typedoc.config.ts": "import {baseTypedocConfig} from '@virmator/docs/configs/typedoc.config.base';\\nimport {join, resolve} from 'node:path';\\nimport type {TypeDocOptions} from 'typedoc';\\n\\nconst repoRoot = resolve(import.meta.dirname, '..');\\nconst indexTsFile = join(repoRoot, 'src', 'index.ts');\\n\\nexport const typeDocConfig: Partial<TypeDocOptions> = {\\n ...baseTypedocConfig,\\n out: join(repoRoot, 'dist-docs'),\\n entryPoints: [\\n indexTsFile,\\n ],\\n intentionallyNotExported: [],\\n defaultCategory: 'MISSING CATEGORY',\\n categoryOrder: [\\n 'Main',\\n 'Internal',\\n ],\\n};\\n"
44
44
}
@@ -52,12 +52,12 @@ exports[`Docs > fails typedoc check 1`] = `
52
52
exports[`Docs > fails unfinished readme 1`] = `
53
53
{
54
54
"logs": {
55
- "stdout": "Copied typedoc.config.ts\\nInstalling
[email protected] [email protected] .
5 ...\\n> npx md-code --check 'README.md'\\nChecking that code in markdown is up to date:",
55
+ "stdout": "Copied typedoc.config.ts\\nInstalling
[email protected] [email protected] .
6 ...\\n> npx md-code --check 'README.md'\\nChecking that code in markdown is up to date:",
56
56
"stderr": " README.md: NOT up to date\\nCode in Markdown file(s) is out of date. Run without the \\"check\\" sub-command to update.\\ndocs failed."
57
57
},
58
58
"cwd": "packages/docs/test-files/unfinished-readme",
59
59
"contentsDiff": {
60
- "package.json": "{\\n \\"type\\": \\"module\\",\\n \\"devDependencies\\": {\\n \\"markdown-code-example-inserter\\": \\"^3.0.3\\",\\n \\"typedoc\\": \\"^0.27.5 \\"\\n }\\n}\\n",
60
+ "package.json": "{\\n \\"type\\": \\"module\\",\\n \\"devDependencies\\": {\\n \\"markdown-code-example-inserter\\": \\"^3.0.3\\",\\n \\"typedoc\\": \\"^0.27.6 \\"\\n }\\n}\\n",
61
61
"configs": {
62
62
"typedoc.config.ts": "import {baseTypedocConfig} from '@virmator/docs/configs/typedoc.config.base';\\nimport {join, resolve} from 'node:path';\\nimport type {TypeDocOptions} from 'typedoc';\\n\\nconst repoRoot = resolve(import.meta.dirname, '..');\\nconst indexTsFile = join(repoRoot, 'src', 'index.ts');\\n\\nexport const typeDocConfig: Partial<TypeDocOptions> = {\\n ...baseTypedocConfig,\\n out: join(repoRoot, 'dist-docs'),\\n entryPoints: [\\n indexTsFile,\\n ],\\n intentionallyNotExported: [],\\n defaultCategory: 'MISSING CATEGORY',\\n categoryOrder: [\\n 'Main',\\n 'Internal',\\n ],\\n};\\n"
63
63
}
@@ -71,11 +71,11 @@ exports[`Docs > fails unfinished readme 1`] = `
71
71
exports[`Docs > passes docs check 1`] = `
72
72
{
73
73
"logs": {
74
- "stdout": "Copied typedoc.config.ts\\nInstalling
[email protected] [email protected] .
5 ...\\n> npx md-code --check 'README.md'\\nChecking that code in markdown is up to date:\\n README.md: up to date\\ndocs finished."
74
+ "stdout": "Copied typedoc.config.ts\\nInstalling
[email protected] [email protected] .
6 ...\\n> npx md-code --check 'README.md'\\nChecking that code in markdown is up to date:\\n README.md: up to date\\ndocs finished."
75
75
},
76
76
"cwd": "packages/docs/test-files/valid-docs",
77
77
"contentsDiff": {
78
- "package.json": "{\\n \\"type\\": \\"module\\",\\n \\"devDependencies\\": {\\n \\"markdown-code-example-inserter\\": \\"^3.0.3\\",\\n \\"typedoc\\": \\"^0.27.5 \\"\\n }\\n}\\n",
78
+ "package.json": "{\\n \\"type\\": \\"module\\",\\n \\"devDependencies\\": {\\n \\"markdown-code-example-inserter\\": \\"^3.0.3\\",\\n \\"typedoc\\": \\"^0.27.6 \\"\\n }\\n}\\n",
79
79
"configs": {
80
80
"typedoc.config.ts": "import {baseTypedocConfig} from '@virmator/docs/configs/typedoc.config.base';\\nimport {join, resolve} from 'node:path';\\nimport type {TypeDocOptions} from 'typedoc';\\n\\nconst repoRoot = resolve(import.meta.dirname, '..');\\nconst indexTsFile = join(repoRoot, 'src', 'index.ts');\\n\\nexport const typeDocConfig: Partial<TypeDocOptions> = {\\n ...baseTypedocConfig,\\n out: join(repoRoot, 'dist-docs'),\\n entryPoints: [\\n indexTsFile,\\n ],\\n intentionallyNotExported: [],\\n defaultCategory: 'MISSING CATEGORY',\\n categoryOrder: [\\n 'Main',\\n 'Internal',\\n ],\\n};\\n"
81
81
}
@@ -119,12 +119,12 @@ exports[`Docs > runs on mono-repo packages 1`] = `
119
119
exports[`Docs > runs typedoc and md-code 1`] = `
120
120
{
121
121
"logs": {
122
- "stdout": "Copied typedoc.config.ts\\nInstalling
[email protected] [email protected] .
5 ...\\n> npx md-code 'README.md'\\nInserting code into markdown:\\n README.md\\ndocs finished."
122
+ "stdout": "Copied typedoc.config.ts\\nInstalling
[email protected] [email protected] .
6 ...\\n> npx md-code 'README.md'\\nInserting code into markdown:\\n README.md\\ndocs finished."
123
123
},
124
124
"cwd": "packages/docs/test-files/unfinished-readme",
125
125
"contentsDiff": {
126
126
"README.md": "here's a markdown code block\\n\\n<!-- example-link: src/readme-examples/thing.example.ts -->\\n\\n\`\`\`TypeScript\\nfunction doThing() {\\n console.info('hi');\\n return 'bye';\\n}\\n\\ndoThing();\\n\`\`\`\\n",
127
- "package.json": "{\\n \\"type\\": \\"module\\",\\n \\"devDependencies\\": {\\n \\"markdown-code-example-inserter\\": \\"^3.0.3\\",\\n \\"typedoc\\": \\"^0.27.5 \\"\\n }\\n}\\n",
127
+ "package.json": "{\\n \\"type\\": \\"module\\",\\n \\"devDependencies\\": {\\n \\"markdown-code-example-inserter\\": \\"^3.0.3\\",\\n \\"typedoc\\": \\"^0.27.6 \\"\\n }\\n}\\n",
128
128
"configs": {
129
129
"typedoc.config.ts": "import {baseTypedocConfig} from '@virmator/docs/configs/typedoc.config.base';\\nimport {join, resolve} from 'node:path';\\nimport type {TypeDocOptions} from 'typedoc';\\n\\nconst repoRoot = resolve(import.meta.dirname, '..');\\nconst indexTsFile = join(repoRoot, 'src', 'index.ts');\\n\\nexport const typeDocConfig: Partial<TypeDocOptions> = {\\n ...baseTypedocConfig,\\n out: join(repoRoot, 'dist-docs'),\\n entryPoints: [\\n indexTsFile,\\n ],\\n intentionallyNotExported: [],\\n defaultCategory: 'MISSING CATEGORY',\\n categoryOrder: [\\n 'Main',\\n 'Internal',\\n ],\\n};\\n"
130
130
}
@@ -135,12 +135,12 @@ exports[`Docs > runs typedoc and md-code 1`] = `
135
135
exports[`Docs > skips private repo typedoc 1`] = `
136
136
{
137
137
"logs": {
138
- "stdout": "Copied typedoc.config.ts\\nInstalling
[email protected] [email protected] .
5 ...\\n> npx md-code 'README.md'\\nSkipping typedoc generation in private repo b\\ndocs finished.",
138
+ "stdout": "Copied typedoc.config.ts\\nInstalling
[email protected] [email protected] .
6 ...\\n> npx md-code 'README.md'\\nSkipping typedoc generation in private repo b\\ndocs finished.",
139
139
"stderr": "No markdown files given to insert code into."
140
140
},
141
141
"cwd": "packages/docs/test-files/mono-repo/packages/b",
142
142
"contentsDiff": {
143
- "package.json": "{\\n \\"name\\": \\"b\\",\\n \\"private\\": true,\\n \\"type\\": \\"module\\",\\n \\"devDependencies\\": {\\n \\"markdown-code-example-inserter\\": \\"^3.0.3\\",\\n \\"typedoc\\": \\"^0.27.5 \\"\\n }\\n}\\n",
143
+ "package.json": "{\\n \\"name\\": \\"b\\",\\n \\"private\\": true,\\n \\"type\\": \\"module\\",\\n \\"devDependencies\\": {\\n \\"markdown-code-example-inserter\\": \\"^3.0.3\\",\\n \\"typedoc\\": \\"^0.27.6 \\"\\n }\\n}\\n",
144
144
"configs": {
145
145
"typedoc.config.ts": "import {baseTypedocConfig} from '@virmator/docs/configs/typedoc.config.base';\\nimport {join, resolve} from 'node:path';\\nimport type {TypeDocOptions} from 'typedoc';\\n\\nconst repoRoot = resolve(import.meta.dirname, '..');\\nconst indexTsFile = join(repoRoot, 'src', 'index.ts');\\n\\nexport const typeDocConfig: Partial<TypeDocOptions> = {\\n ...baseTypedocConfig,\\n out: join(repoRoot, 'dist-docs'),\\n entryPoints: [\\n indexTsFile,\\n ],\\n intentionallyNotExported: [],\\n defaultCategory: 'MISSING CATEGORY',\\n categoryOrder: [\\n 'Main',\\n 'Internal',\\n ],\\n};\\n"
146
146
}
0 commit comments