mattiaerre / oc-hub

This repository has been created as a central hub for all the OpenComponents built by Mattia Richetto.
10 stars 2 forks source link

Ideas for `https://github.com/opentable/oc-testing` #1

Closed mattiaerre closed 7 years ago

mattiaerre commented 7 years ago

Description

I really enjoy working w/ Jest nowadays and I believe that is a very good choice for testing JavaScript both client and server side; I've created this repo that I am using in order to collect the components that I am building and I would like to share w/ you oc-timeago.

As you can see there is a server.spec.js file containing tests asserting against the model; I'd love to use the same approach in order to refactor the oc-testing repository that uses at the moment mocha & chai instead of Jest.

If you think this is a good idea I will proceed as soon as possible w/ a PR.

P.S. is it possible to have moment available at the https://oc-registry.herokuapp.com/ registry so that we will be able to have a running version of the oc-timeago component? Thanks!

// cc @matteofigus @nickbalestra

matteofigus commented 7 years ago

I love jest and love the idea. Only thing, I don't know if to keep both (jest + non jest) or just to include jest for everything.

Perhaps including both options (mocha and jest tests) is good anyway as first step?

mattiaerre commented 7 years ago

@matteofigus let's try to do that: I will add additional tests done w/ Jest so that we can compare them and see which approach is better 😉 ... sounds like a plan?

matteofigus commented 7 years ago

awesome! Thanks :)

mattiaerre commented 7 years ago

this will be fixed w/ this PR:

https://github.com/opentable/oc-testing/pull/1

// @matteofigus

mattiaerre commented 7 years ago

closing because of

https://github.com/opencomponents/oc-testing/pull/1