Ml5-library: Unit Testing and CI

Created on 31 Jan 2018  路  11Comments  路  Source: ml5js/ml5-library

As briefly discussed with @shiffman, this project should at some point have a testing framework and CI

devops feature request good first issue help wanted

Most helpful comment

commits af5d848 and 5f31edc added support for Jest and a short description in the CONTRIBUTING.md guide on how to run and create tests.

There's also a new description for the website in CONTRIBUTING.md

We can now start creating unit test.

Next steps will be to implement CI and better merging and branching practices.

All 11 comments

I have been learning jest for a video about "continuous integration" so would be glad to participate in helping get this started!

just chiming in to give encouragement for this鈥攁 test framework and CI makes it so much easier for people to contribute to an open source project.

Let's discuss tomorrow! Maybe I can do a quick tutorial as practice for my video tutorial and anyone who wants to could work on it at the meeting.

sounds good!

Making a list of tests:

  • [ ] for utils.js test correct image output for a given input.
  • [ ] test models -- squeezenet

to be continued. . . .

commits af5d848 and 5f31edc added support for Jest and a short description in the CONTRIBUTING.md guide on how to run and create tests.

There's also a new description for the website in CONTRIBUTING.md

We can now start creating unit test.

Next steps will be to implement CI and better merging and branching practices.

Wonderful, I just did a video tutorial series about testing and CI (with jest and CircleCI). When those are published I can include that as material for getting started contributing. . .

As a matter of update CircleCI is now integrated with #50. We'll certainly want more tests but we're off and running! I'll leave this open for now but we can eventually transition to individual issues for tests.

We are considering switching from Jest to Karma. (And maybe from CircleCI to TravisCI?) Jest doesn't seem particularly well suited for browser libraries (but I could be wrong!). Deeplearn.js uses Karma and Travis so mirroring their workflow makes a lot of sense. (Big thanks to @dariusk for all of the thoughts and advice about this today!)

Tagging @nsthorat and @dsmilkov for any thoughts from their experience.

I don't know much about Jest, but Karma + Jasmine have worked great for us. Works great with travis + browserstack (if you want to run tests on real devices for free).

working on this one!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

shiffman picture shiffman  路  5Comments

sci2lab picture sci2lab  路  5Comments

yining1023 picture yining1023  路  9Comments

shiffman picture shiffman  路  8Comments

joeyklee picture joeyklee  路  5Comments