Skip to content

Commit bda2f17

Browse files
committed
vault: Make convert_test_data_markdown_to_js.js match AllCacheSampleData.ts
1 parent 44c406b commit bda2f17

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

resources/sample_vaults/Tasks-Demo/_meta/templater_scripts/convert_test_data_markdown_to_js.js

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,19 +135,27 @@ export type MockDataName =
135135
136136
/**
137137
* Names of all the sample data in \`resources/sample_vaults/Tasks-Demo/Test Data\`.
138+
*
139+
* To read all the tasks in all the sample data files,
140+
* use {@link readAllTasksFromAllSimulatedFiles}
141+
*
138142
* Example use:
139143
*
140144
* \`\`\`typescript
141-
* const tasks: Task[] = AllMockDataNames.flatMap((testDataName) => {
142-
* return readTasksFromSimulatedFile(testDataName);
145+
* let output = '';
146+
* AllMockDataNames.forEach((file) => {
147+
* const tasksFile = getTasksFileFromMockData(file);
148+
* output += visualiseLinks(tasksFile.outlinksInProperties, file);
143149
* });
150+
* verifyMarkdown(output);
144151
* \`\`\`
145152
*
146153
* Related code that uses some or all of this data:
147154
* - {@link SimulatedFile}
148155
* - {@link readTasksFromSimulatedFile}
149156
* - {@link getTasksFileFromMockData}
150157
* - {@link listPathAndData}
158+
* - {@link readAllTasksFromAllSimulatedFiles}
151159
*/
152160
export const AllMockDataNames: MockDataName[] = [
153161
'${basenames.join("',\n '")}',

0 commit comments

Comments
 (0)