swagger project test shows [SyntaxError: Unexpected identifier]

I’ve been working with Swagger to make an API server. With it, I created https://myopenbazaar.top. Pretty cool software, but I found testing with it pretty confusing. Swagger abstracts away mochajs, and for whatever reason, Swagger was hiding a stack trace of a failure when I was doing testing.

That’s so not helpful!

Looking for a fix, I found that running mocha directly did the trick. It needed to be called with the --recursive flag, because swagger creates tests several levels deep in a directory tree.

Much better. Now I can actually tell what the problem is!

Leave a Reply

Your email address will not be published.