sympy / sympy_gamma

A SymPy version of WolframAlpha.
https://sympygamma.com
Other
666 stars 112 forks source link

Tests for SymPy Gamma #42

Open sahilshekhawat opened 10 years ago

sahilshekhawat commented 10 years ago

Recently I found out that my PR #33 where i sorted a dictionary actually created another issue with satisfiable which needed another PR #39, So i think we should add tests in Django. This will actually help us a lot while reviewing.

sahilshekhawat commented 10 years ago

I want to work on it but first i want to know whether it needs to be done or not, I have done this mistake before

debugger22 commented 10 years ago

Yeah. I was going to propose that. Enabling CI will help a lot.

sahilshekhawat commented 10 years ago

@lidavidm What do you suggest?

lidavidm commented 10 years ago

I was thinking we could configure Travis CI to run Python unittests on resultsets.py and to run CasperJS (PhantomJS) tests on the actual UI; Travis supports both.

sahilshekhawat commented 10 years ago

Okay, this seems to be a nicer way but I don't know much about Casper/Phantom JS. Let me go through them and then I will send a PR right away. Will ask If I have any trouble. On 4 May 2014 20:18, "David Li" notifications@github.com wrote:

I was thinking we could configure Travis CI to run Python unittests on resultsets.py and to run CasperJS http://casperjs.org/ (PhantomJShttp://www.phantomjs.org/) tests on the actual UI; Travis supports both.

— Reply to this email directly or view it on GitHubhttps://github.com/sympy/sympy_gamma/issues/42#issuecomment-42134598 .

lidavidm commented 10 years ago

Basically, the Python unittests would just make sure that the functions in resultsets.py provide the output that is expected (not necessarily that Gamma is displaying it correctly). Testing that expressions parse correctly would also be nice (as Gamma adds additional capability beyond SymPy's parsing, like synonyms, that SymPy doesn't test). CasperJS is a headless browser; it can render webpages without a GUI and allow JavaScript to inspect and manipulate them. With this we could, for instance:

Travis CI can be configured to run these tests automatically on pull requests. To run the CasperJS tests we would have to set up Travis to run the development server so that CasperJS can connect to it, thus, we would have to download the App Engine SDK on Travis CI (look this up on Google).

sahilshekhawat commented 10 years ago

Ah! Thanks David Okay, I am on to it.

lidavidm commented 10 years ago

@sahilshekhawat FYI, I'm working on the Travis configuration right now.

sahilshekhawat commented 10 years ago

okay then, i can work on the unit-tests in python. :)

On Mon, May 5, 2014 at 7:49 AM, David Li notifications@github.com wrote:

@sahilshekhawat https://github.com/sahilshekhawat FYI, I'm working on the Travis configuration right now.

— Reply to this email directly or view it on GitHubhttps://github.com/sympy/sympy_gamma/issues/42#issuecomment-42154838 .