quick question: I’d like to implement some simple HTTP API tests and JSON validations using the serverless CLI test command and the serverless.test.yml, is it still supported as described in this page: Serverless Dashboard - Testing?
I’ll move to Jest later but for now this would have been enough.
I have the serverless.yml api function as below:
functions: api: handler: app.handler events: - httpApi: "*"
And this serverless.test.yml:
name: "Categories list" endpoint: function: api method: POST path: /categories response: status: 200
Trying the command just tells me this:
$ serverless test Running "serverless" from node_modules Environment: darwin, node 16.16.0, framework 3.20.0 (local) 3.22.0v (global), plugin 6.2.2, SDK 4.3.2 Error: Run "serverless" to configure your service for testing.
Any advice on this?
Thanks a lot in advance.