Closed syzer closed 6 years ago
This looks correct to me, thanks. We usually use jest, so that would be nicer here, although the test itself looks fine. Thanks for contributing!
@Haroenv no problem.. great work guys! About tests : some(integration) tests are better than 0 tests? , right? :)
Ava is way faster for smaller projects ( jest
startup time is really bad)
And jest I usually do with tap assert jest-t-assert
IMHO:
mocha asserts expect(bla).toBe(bla)
is quite ugly
and don't let you do short code like this:
test('Flatten form before send to backend ', t =>
t.deepEqual(flattenObject(momentForm), expected) &&
t.deepEqual(flattenObject(normalForm), expected))
Do you want me to rewrite it to jest/mocha test runner? Or this PR could be merged ?
This is not my personal project, but rather of @iam4x, so it's up to him. As you said, a test is better than no test. I think it depends on how much you'd like to contribute to this or write more tests if necessary. We wrote this program originally in a internal hackathon, which is also why it didn't initially have tests.
I'll leave it up to Maxime to decide
getSubtitles()