Third-Culture-Software / bhima

A hospital information management application for rural Congolese hospitals
https://docs.bhi.ma/
GNU General Public License v2.0
218 stars 104 forks source link

Investigate other test runners #1661

Open jniles opened 7 years ago

jniles commented 7 years ago

We settled on mocha and chai because we figured it would be easy to write tests in. From a maintainability standpoint, we should probably prefer speed and flexibility over the ease of writing tests. The good news is that, now that we've written a comprehensive test suite, we might be able to easily transpose it into another runner with advantages in parallelism and other nice features.

We should investigate what other test runners have to offer:

  1. ava - runs everything in ES2016 by default, built in promise integration, and parallel by default. I have experience using it in wenge.
  2. chakram - essentially chaijs 2.0
  3. supertest - an old one, but maintained.
jniles commented 7 years ago

I'm intrigued by avajs and will try migrating our tests to it as an experiment. Since it is "parallel-first", we should be able to accomplish the goals of having tests running with different shards accessing fresh databases when I am done.

Note: This is only for integration testing.