cograph icon indicating copy to clipboard operation
cograph copied to clipboard

Write additional tests

Open willzeng opened this issue 11 years ago • 12 comments

Perhaps using jasmine: http://jasmine.github.io/

willzeng avatar May 09 '14 09:05 willzeng

I'll get Jasmine set up and write a unit test for one of the models.

vpontis avatar May 09 '14 10:05 vpontis

Yep great.

On Fri, May 9, 2014 at 11:06 AM, Victor Pontis [email protected]:

I'll get Jasmine set up and write a unit test for one of the models.

— Reply to this email directly or view it on GitHubhttps://github.com/willzeng/rhizi-client/issues/66#issuecomment-42651102 .

willzeng avatar May 09 '14 10:05 willzeng

Don't bang your head against it too much though. It's something we'll all need to get the hang of so I'm happy for it to be on the agenda for Monday morning.

So jasmine-node still seems to be the way to go? codeship tutorial

willzeng avatar May 09 '14 19:05 willzeng

@davidfurlong Can we get an update here as to your progress on this? It would be great to get even the most basic basic setup pushed to a branch at some point.

willzeng avatar May 28 '14 14:05 willzeng

Well i've run into errors trying to use jasmine-node and I'm finding it hard to progress. This attempt is on jasmine-test branch.

davidfurlong avatar May 28 '14 14:05 davidfurlong

This is still an issue no? Though we dont need to have it on the alpha milestone.

willzeng avatar Sep 29 '14 09:09 willzeng

I've been very happy with mocha + chai for testing server side (nodejs) code. Here's an example from my latest project of how the tests look: https://github.com/nodesphere/nodesphere/blob/master/test/core/node_tests.coffee

Does this sounds interesting, or do you prefer Jasmine?

harlantwood avatar May 13 '15 18:05 harlantwood

Ah, I found your tests in https://github.com/willzeng/cograph/tree/dev/app/tests -- are these working for you? If so, maybe close this issue? If not, why not?

harlantwood avatar May 13 '15 18:05 harlantwood

The test setup is working, but we haven't written ones that we need in order to increase the reliability of a build. This issue is more about writing particular tests than setting up the test environment.

davidfurlong avatar May 13 '15 18:05 davidfurlong

That said if you have suggestions for better ways to set the tests up they would be welcome! Now would be the time to switch away from Jasmine before tests are written.

On Wed, May 13, 2015, 19:27 David Furlong [email protected] wrote:

The test setup is working, but we haven't written ones that we need in order to increase the reliability of a build. This issue is more about writing particular tests than setting up the test environment.

— Reply to this email directly or view it on GitHub https://github.com/willzeng/cograph/issues/66#issuecomment-101768227.

willzeng avatar May 13 '15 19:05 willzeng

Cool. I got the current tests to run by doing:

http-server
open http://localhost:8080/app/tests/SpecRunner.html

Is there a way to run them from the command line as well?

harlantwood avatar May 14 '15 06:05 harlantwood

Yep spot on that's it. I'm not sure of any way to see them in the command line as Jasmine really does seem to run them in the browser. Would be an improvement if there was a way.

On Thu, May 14, 2015 at 7:35 AM Harlan T Wood [email protected] wrote:

Cool. I got the current tests to run by doing:

http-server open http://localhost:8080/app/tests/SpecRunner.html

Is there a way to run them from the command line as well?

— Reply to this email directly or view it on GitHub https://github.com/willzeng/cograph/issues/66#issuecomment-101936876.

willzeng avatar May 14 '15 18:05 willzeng