|
| 1 | +/* IMPORTANT |
| 2 | + * This snapshot file is auto-generated, but designed for humans. |
| 3 | + * It should be checked into source control and tracked carefully. |
| 4 | + * Re-generate by setting TAP_SNAPSHOT=1 and running tests. |
| 5 | + * Make sure to inspect the output below. Do not ignore changes! |
| 6 | + */ |
| 7 | +'use strict' |
| 8 | +exports[`test/lib/commands/run-script.js TAP list scripts no args > basic report 1`] = ` |
| 9 | +Lifecycle scripts included in x@1.2.3: |
| 10 | + test |
| 11 | + exit 2 |
| 12 | + start |
| 13 | + node server.js |
| 14 | + stop |
| 15 | + node kill-server.js |
| 16 | +
|
| 17 | +available via \`npm run-script\`: |
| 18 | + preenv |
| 19 | + echo before the env |
| 20 | + postenv |
| 21 | + echo after the env |
| 22 | +` |
| 23 | + |
| 24 | +exports[`test/lib/commands/run-script.js TAP list scripts parseable > must match snapshot 1`] = ` |
| 25 | +test:exit 2 |
| 26 | +start:node server.js |
| 27 | +stop:node kill-server.js |
| 28 | +preenv:echo before the env |
| 29 | +postenv:echo after the env |
| 30 | +` |
| 31 | + |
| 32 | +exports[`test/lib/commands/run-script.js TAP list scripts warn json > json report 1`] = ` |
| 33 | +{ |
| 34 | + "test": "exit 2", |
| 35 | + "start": "node server.js", |
| 36 | + "stop": "node kill-server.js", |
| 37 | + "preenv": "echo before the env", |
| 38 | + "postenv": "echo after the env" |
| 39 | +} |
| 40 | +` |
| 41 | + |
| 42 | +exports[`test/lib/commands/run-script.js TAP list scripts, only commands > must match snapshot 1`] = ` |
| 43 | +Lifecycle scripts included in x@1.2.3: |
| 44 | + preversion |
| 45 | + echo doing the version dance |
| 46 | +` |
| 47 | + |
| 48 | +exports[`test/lib/commands/run-script.js TAP list scripts, only non-commands > must match snapshot 1`] = ` |
| 49 | +Scripts available in x@1.2.3 via \`npm run-script\`: |
| 50 | + glorp |
| 51 | + echo doing the glerp glop |
| 52 | +` |
| 53 | + |
| 54 | +exports[`test/lib/commands/run-script.js TAP workspaces failed workspace run with succeeded runs > should log error msgs for each workspace script 1`] = ` |
| 55 | +Lifecycle script \`glorp\` failed with error: |
| 56 | +Error: ERR |
| 57 | + in workspace: a@1.0.0 |
| 58 | + at location: {CWD}/prefix/packages/a |
| 59 | +` |
| 60 | + |
| 61 | +exports[`test/lib/commands/run-script.js TAP workspaces list all scripts --json > must match snapshot 1`] = ` |
| 62 | +{ |
| 63 | + "a": { |
| 64 | + "glorp": "echo a doing the glerp glop" |
| 65 | + }, |
| 66 | + "b": { |
| 67 | + "glorp": "echo b doing the glerp glop" |
| 68 | + }, |
| 69 | + "c": { |
| 70 | + "test": "exit 0", |
| 71 | + "posttest": "echo posttest", |
| 72 | + "lorem": "echo c lorem" |
| 73 | + }, |
| 74 | + "d": { |
| 75 | + "test": "exit 0", |
| 76 | + "posttest": "echo posttest" |
| 77 | + }, |
| 78 | + "e": { |
| 79 | + "test": "exit 0", |
| 80 | + "start": "echo start something" |
| 81 | + }, |
| 82 | + "noscripts": {} |
| 83 | +} |
| 84 | +` |
| 85 | + |
| 86 | +exports[`test/lib/commands/run-script.js TAP workspaces list all scripts --parseable > must match snapshot 1`] = ` |
| 87 | +a:glorp:echo a doing the glerp glop |
| 88 | +b:glorp:echo b doing the glerp glop |
| 89 | +c:test:exit 0 |
| 90 | +c:posttest:echo posttest |
| 91 | +c:lorem:echo c lorem |
| 92 | +d:test:exit 0 |
| 93 | +d:posttest:echo posttest |
| 94 | +e:test:exit 0 |
| 95 | +e:start:echo start something |
| 96 | +` |
| 97 | + |
| 98 | +exports[`test/lib/commands/run-script.js TAP workspaces list all scripts > must match snapshot 1`] = ` |
| 99 | +Scripts available in a@1.0.0 via \`npm run-script\`: |
| 100 | + glorp |
| 101 | + echo a doing the glerp glop |
| 102 | +
|
| 103 | +Scripts available in b@2.0.0 via \`npm run-script\`: |
| 104 | + glorp |
| 105 | + echo b doing the glerp glop |
| 106 | +
|
| 107 | +Lifecycle scripts included in c@1.0.0: |
| 108 | + test |
| 109 | + exit 0 |
| 110 | + posttest |
| 111 | + echo posttest |
| 112 | +
|
| 113 | +available via \`npm run-script\`: |
| 114 | + lorem |
| 115 | + echo c lorem |
| 116 | +
|
| 117 | +Lifecycle scripts included in d@1.0.0: |
| 118 | + test |
| 119 | + exit 0 |
| 120 | + posttest |
| 121 | + echo posttest |
| 122 | +
|
| 123 | +Lifecycle scripts included in e: |
| 124 | + test |
| 125 | + exit 0 |
| 126 | + start |
| 127 | + echo start something |
| 128 | +` |
| 129 | + |
| 130 | +exports[`test/lib/commands/run-script.js TAP workspaces list all scripts with colors > must match snapshot 1`] = ` |
| 131 | +[1mScripts[22m available in [32ma@1.0.0[39m via \`[34mnpm run-script[39m\`: |
| 132 | + glorp |
| 133 | + [2mecho a doing the glerp glop[22m |
| 134 | +
|
| 135 | +[1mScripts[22m available in [32mb@2.0.0[39m via \`[34mnpm run-script[39m\`: |
| 136 | + glorp |
| 137 | + [2mecho b doing the glerp glop[22m |
| 138 | +
|
| 139 | +[0m[1mLifecycle scripts[22m[0m included in [32mc@1.0.0[39m: |
| 140 | + test |
| 141 | + [2mexit 0[22m |
| 142 | + posttest |
| 143 | + [2mecho posttest[22m |
| 144 | +
|
| 145 | +available via \`[34mnpm run-script[39m\`: |
| 146 | + lorem |
| 147 | + [2mecho c lorem[22m |
| 148 | +
|
| 149 | +[0m[1mLifecycle scripts[22m[0m included in [32md@1.0.0[39m: |
| 150 | + test |
| 151 | + [2mexit 0[22m |
| 152 | + posttest |
| 153 | + [2mecho posttest[22m |
| 154 | +
|
| 155 | +[0m[1mLifecycle scripts[22m[0m included in [32me[39m: |
| 156 | + test |
| 157 | + [2mexit 0[22m |
| 158 | + start |
| 159 | + [2mecho start something[22m |
| 160 | +` |
| 161 | + |
| 162 | +exports[`test/lib/commands/run-script.js TAP workspaces list regular scripts, filtered by name > must match snapshot 1`] = ` |
| 163 | +Scripts available in a@1.0.0 via \`npm run-script\`: |
| 164 | + glorp |
| 165 | + echo a doing the glerp glop |
| 166 | +
|
| 167 | +Scripts available in b@2.0.0 via \`npm run-script\`: |
| 168 | + glorp |
| 169 | + echo b doing the glerp glop |
| 170 | +` |
| 171 | + |
| 172 | +exports[`test/lib/commands/run-script.js TAP workspaces list regular scripts, filtered by parent folder > must match snapshot 1`] = ` |
| 173 | +Scripts available in a@1.0.0 via \`npm run-script\`: |
| 174 | + glorp |
| 175 | + echo a doing the glerp glop |
| 176 | +
|
| 177 | +Scripts available in b@2.0.0 via \`npm run-script\`: |
| 178 | + glorp |
| 179 | + echo b doing the glerp glop |
| 180 | +
|
| 181 | +Lifecycle scripts included in c@1.0.0: |
| 182 | + test |
| 183 | + exit 0 |
| 184 | + posttest |
| 185 | + echo posttest |
| 186 | +
|
| 187 | +available via \`npm run-script\`: |
| 188 | + lorem |
| 189 | + echo c lorem |
| 190 | +
|
| 191 | +Lifecycle scripts included in d@1.0.0: |
| 192 | + test |
| 193 | + exit 0 |
| 194 | + posttest |
| 195 | + echo posttest |
| 196 | +
|
| 197 | +Lifecycle scripts included in e: |
| 198 | + test |
| 199 | + exit 0 |
| 200 | + start |
| 201 | + echo start something |
| 202 | +` |
| 203 | + |
| 204 | +exports[`test/lib/commands/run-script.js TAP workspaces list regular scripts, filtered by path > must match snapshot 1`] = ` |
| 205 | +Scripts available in a@1.0.0 via \`npm run-script\`: |
| 206 | + glorp |
| 207 | + echo a doing the glerp glop |
| 208 | +` |
| 209 | + |
| 210 | +exports[`test/lib/commands/run-script.js TAP workspaces missing scripts in all workspaces > should log error msgs for each workspace script 1`] = ` |
| 211 | +Lifecycle script \`missing-script\` failed with error: |
| 212 | +Error: Missing script: "missing-script" |
| 213 | +
|
| 214 | +To see a list of scripts, run: |
| 215 | + npm run |
| 216 | + in workspace: a@1.0.0 |
| 217 | + at location: {CWD}/prefix/packages/a |
| 218 | +Lifecycle script \`missing-script\` failed with error: |
| 219 | +Error: Missing script: "missing-script" |
| 220 | +
|
| 221 | +To see a list of scripts, run: |
| 222 | + npm run |
| 223 | + in workspace: b@2.0.0 |
| 224 | + at location: {CWD}/prefix/packages/b |
| 225 | +Lifecycle script \`missing-script\` failed with error: |
| 226 | +Error: Missing script: "missing-script" |
| 227 | +
|
| 228 | +To see a list of scripts, run: |
| 229 | + npm run |
| 230 | + in workspace: c@1.0.0 |
| 231 | + at location: {CWD}/prefix/packages/c |
| 232 | +Lifecycle script \`missing-script\` failed with error: |
| 233 | +Error: Missing script: "missing-script" |
| 234 | +
|
| 235 | +To see a list of scripts, run: |
| 236 | + npm run |
| 237 | + in workspace: d@1.0.0 |
| 238 | + at location: {CWD}/prefix/packages/d |
| 239 | +Lifecycle script \`missing-script\` failed with error: |
| 240 | +Error: Missing script: "missing-script" |
| 241 | +
|
| 242 | +To see a list of scripts, run: |
| 243 | + npm run |
| 244 | + in workspace: e |
| 245 | + at location: {CWD}/prefix/packages/e |
| 246 | +Lifecycle script \`missing-script\` failed with error: |
| 247 | +Error: Missing script: "missing-script" |
| 248 | +
|
| 249 | +To see a list of scripts, run: |
| 250 | + npm run |
| 251 | + in workspace: noscripts@1.0.0 |
| 252 | + at location: {CWD}/prefix/packages/noscripts |
| 253 | +` |
| 254 | + |
| 255 | +exports[`test/lib/commands/run-script.js TAP workspaces missing scripts in some workspaces > should log error msgs for each workspace script 1`] = ` |
| 256 | +Lifecycle script \`test\` failed with error: |
| 257 | +Error: Missing script: "test" |
| 258 | +
|
| 259 | +To see a list of scripts, run: |
| 260 | + npm run |
| 261 | + in workspace: a@1.0.0 |
| 262 | + at location: {CWD}/prefix/packages/a |
| 263 | +Lifecycle script \`test\` failed with error: |
| 264 | +Error: Missing script: "test" |
| 265 | +
|
| 266 | +To see a list of scripts, run: |
| 267 | + npm run |
| 268 | + in workspace: b@2.0.0 |
| 269 | + at location: {CWD}/prefix/packages/b |
| 270 | +` |
| 271 | + |
| 272 | +exports[`test/lib/commands/run-script.js TAP workspaces single failed workspace run > should log error msgs for each workspace script 1`] = ` |
| 273 | +Lifecycle script \`test\` failed with error: |
| 274 | +Error: err |
| 275 | + in workspace: c@1.0.0 |
| 276 | + at location: {CWD}/prefix/packages/c |
| 277 | +` |
0 commit comments