Hi everyone,
I ran into the following error while completing an AWS tutorial: https://github.com/aws-samples/aws-serverless-workshops/tree/master/DevOps/2_ContinuousDeliveryPipeline
> uni-api-test@1.0.0 test C:UsersChris-PCsourcereposUniApiuni-api
> echo ‘Error: no test specified’
‘Error: no test specified’
The solution was to add the following line to my package.json file:
Now when running npm test I get the expected test output:
1 failing
1) Reading Unicorns
errors on missing unicorn data:
AssertionError [ERR_ASSERTION]: 500 == 404
+ expected – actual
-500
+404
at lambda.lambda_handler (testread.spec.js:77:20)
at appread.js:20:10
at Object.get (testread.spec.js:34:33)
at Object.exports.lambda_handler (appread.js:18:13)
at Context. (testread.spec.js:65:16)
npm ERR! Test failed. See above for more details.
Thanks to this link for the answer: https://teamtreehouse.com/community/when-i-run-test-i-am-getting-an-error-that-says-no-test-specified
Leave a Reply