|
| 1 | +// Jest Snapshot v1, https://goo.gl/fbAQLP |
| 2 | + |
| 3 | +exports[`dox parser parse empty string 1`] = ` |
| 4 | +{ |
| 5 | + "methods": [], |
| 6 | + "path": "./test/mocks/empty.js", |
| 7 | +} |
| 8 | +`; |
| 9 | + |
| 10 | +exports[`dox parser parse example jsdoc headers (declaration methods) 1`] = ` |
| 11 | +{ |
| 12 | + "methods": [ |
| 13 | + { |
| 14 | + "description": "Finds file in path. |
| 15 | +
|
| 16 | + console.log(await findFileInPath('./', 'package.json')); |
| 17 | + console.log(await findFileInPath('../', 'package.json')); |
| 18 | + console.log(await findFileInPath('~/git/github/doxdox/', '.package.json'));", |
| 19 | + "fullName": "findFileInPath(input, fileName)", |
| 20 | + "name": "findFileInPath", |
| 21 | + "params": [ |
| 22 | + { |
| 23 | + "description": "Directory to check for file.", |
| 24 | + "name": "input", |
| 25 | + "types": [ |
| 26 | + "string", |
| 27 | + ], |
| 28 | + }, |
| 29 | + { |
| 30 | + "description": "= 'package.json'] File name to check for.", |
| 31 | + "name": "fileName", |
| 32 | + "types": [ |
| 33 | + "string", |
| 34 | + ], |
| 35 | + }, |
| 36 | + ], |
| 37 | + "private": false, |
| 38 | + "returns": [ |
| 39 | + { |
| 40 | + "description": "Path to package.json file.", |
| 41 | + "name": null, |
| 42 | + "types": [ |
| 43 | + "Promise.<string|null>", |
| 44 | + ], |
| 45 | + }, |
| 46 | + ], |
| 47 | + "slug": "test-mocks-declaration-js-findfileinpath", |
| 48 | + "type": "declaration", |
| 49 | + }, |
| 50 | + { |
| 51 | + "description": "Get the current working directory.", |
| 52 | + "fullName": "getCurrentWorkingDirectory()", |
| 53 | + "name": "getCurrentWorkingDirectory", |
| 54 | + "params": [], |
| 55 | + "private": false, |
| 56 | + "returns": [ |
| 57 | + { |
| 58 | + "description": "Directory path.", |
| 59 | + "name": null, |
| 60 | + "types": [ |
| 61 | + "string", |
| 62 | + ], |
| 63 | + }, |
| 64 | + ], |
| 65 | + "slug": "test-mocks-declaration-js-getcurrentworkingdirectory", |
| 66 | + "type": "declaration", |
| 67 | + }, |
| 68 | + { |
| 69 | + "description": "Get the root directory of the package, supplied path or URL.", |
| 70 | + "fullName": "getRootDirPath(url)", |
| 71 | + "name": "getRootDirPath", |
| 72 | + "params": [ |
| 73 | + { |
| 74 | + "description": "Optional path or URL.", |
| 75 | + "name": "url", |
| 76 | + "types": [ |
| 77 | + "string", |
| 78 | + ], |
| 79 | + }, |
| 80 | + ], |
| 81 | + "private": false, |
| 82 | + "returns": [ |
| 83 | + { |
| 84 | + "description": "Directory path.", |
| 85 | + "name": null, |
| 86 | + "types": [ |
| 87 | + "string", |
| 88 | + ], |
| 89 | + }, |
| 90 | + ], |
| 91 | + "slug": "test-mocks-declaration-js-getrootdirpath", |
| 92 | + "type": "declaration", |
| 93 | + }, |
| 94 | + ], |
| 95 | + "path": "./test/mocks/declaration.js", |
| 96 | +} |
| 97 | +`; |
| 98 | + |
| 99 | +exports[`dox parser parse example jsdoc headers (function methods) 1`] = ` |
| 100 | +{ |
| 101 | + "methods": [ |
| 102 | + { |
| 103 | + "description": "Finds file in path. |
| 104 | +
|
| 105 | + console.log(await findFileInPath('./', 'package.json')); |
| 106 | + console.log(await findFileInPath('../', 'package.json')); |
| 107 | + console.log(await findFileInPath('~/git/github/doxdox/', '.package.json'));", |
| 108 | + "fullName": "findFileInPath(input, fileName)", |
| 109 | + "name": "findFileInPath", |
| 110 | + "params": [ |
| 111 | + { |
| 112 | + "description": "Directory to check for file.", |
| 113 | + "name": "input", |
| 114 | + "types": [ |
| 115 | + "string", |
| 116 | + ], |
| 117 | + }, |
| 118 | + { |
| 119 | + "description": "= 'package.json'] File name to check for.", |
| 120 | + "name": "fileName", |
| 121 | + "types": [ |
| 122 | + "string", |
| 123 | + ], |
| 124 | + }, |
| 125 | + ], |
| 126 | + "private": false, |
| 127 | + "returns": [ |
| 128 | + { |
| 129 | + "description": "Path to package.json file.", |
| 130 | + "name": null, |
| 131 | + "types": [ |
| 132 | + "Promise.<string|null>", |
| 133 | + ], |
| 134 | + }, |
| 135 | + ], |
| 136 | + "slug": "test-mocks-declaration-js-findfileinpath", |
| 137 | + "type": "declaration", |
| 138 | + }, |
| 139 | + { |
| 140 | + "description": "Get the current working directory.", |
| 141 | + "fullName": "getCurrentWorkingDirectory()", |
| 142 | + "name": "getCurrentWorkingDirectory", |
| 143 | + "params": [], |
| 144 | + "private": false, |
| 145 | + "returns": [ |
| 146 | + { |
| 147 | + "description": "Directory path.", |
| 148 | + "name": null, |
| 149 | + "types": [ |
| 150 | + "string", |
| 151 | + ], |
| 152 | + }, |
| 153 | + ], |
| 154 | + "slug": "test-mocks-declaration-js-getcurrentworkingdirectory", |
| 155 | + "type": "declaration", |
| 156 | + }, |
| 157 | + { |
| 158 | + "description": "Get the root directory of the package, supplied path or URL.", |
| 159 | + "fullName": "getRootDirPath(url)", |
| 160 | + "name": "getRootDirPath", |
| 161 | + "params": [ |
| 162 | + { |
| 163 | + "description": "Optional path or URL.", |
| 164 | + "name": "url", |
| 165 | + "types": [ |
| 166 | + "string", |
| 167 | + ], |
| 168 | + }, |
| 169 | + ], |
| 170 | + "private": false, |
| 171 | + "returns": [ |
| 172 | + { |
| 173 | + "description": "Directory path.", |
| 174 | + "name": null, |
| 175 | + "types": [ |
| 176 | + "string", |
| 177 | + ], |
| 178 | + }, |
| 179 | + ], |
| 180 | + "slug": "test-mocks-declaration-js-getrootdirpath", |
| 181 | + "type": "declaration", |
| 182 | + }, |
| 183 | + ], |
| 184 | + "path": "./test/mocks/declaration.js", |
| 185 | +} |
| 186 | +`; |
0 commit comments