Closed DK318 closed 2 years ago
I was thinking, since the tests need a bit of rework anyway (to make them pass + make them independent from each other + write missing tests), maybe we could take the opportunity to rewrite them in Haskell.
The main reason why they were written in javascript in the first place was so that they would serve as documentation for whoever writes the frontend. However:
I think we could still achieve our goal (documenting the web API) if we re-write the tests in Haskell, without using a servant client and without relying on coffer's data types/encoders/decoders. We could just write json literals in the tests (e.g. with aesonQQ
), manually add the headers, etc.
What do you think @DK318 ?
Plus, the setup/cleanup steps of spinning up 2 web servers before running the tests & killing them when the tests are done would be a lot easier as well.
Hmm. I think it really would be better if tests were written in Haskell. Personally, I don't know mocha
at all :smile:
Cool, I'll close a few test-related issues and open a new one ^^
Blocked by #37
Clarification and motivation
After rebases
mocha
tests stopped working. We should reanimate them.Acceptance criteria
mocha
tests are working and passing.