Posted by Magnity on August 10, 2009 at 2:46pm
Jump to:
| Project: | Storm |
| Version: | 6.x-1.x-dev |
| Component: | Miscellaneous |
| Category: | task |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed (fixed) |
Issue Summary
It seems accepted across Drupal modules now that tests are a good way of spotting if bugs are introduced into a module, or if a module breaks a different part of Drupal.
Therefore it would be useful to have a few tests written for Storm.
Lets use this issue to suggest and discuss tests that may be useful - and new particular issues for posting each test and the associated tracking of committing them to Storm.
Comments
#1
Seems to me we should start with the basics.
1.) Creation of each node type which is generally to say make sure all the form rendering happens correctly
2.) Tests that attempt to create nodes without required fields, making sure it's not allowed
3.) Creation of nodes without correct dependencies (ie try and create a time tracking without appyling it to a project/task/ticket, create a team without there being any people saved in Storm, etc..)
4.) Try and pass bad variables into functions (ie pass strings into # of days you have for billing)
Then move into testing the same things with different admin settings, ie create an invoice tax settings set to "do not apply" and make sure it is created, etc...)
Of course that could make for a lot of issues, if we do one issue per test.
#2
Yes - a lot of issues, but the best thing will be that Storm ships with the tests attached. So individual issues will come and go as they are committed to CVS.
#3
On the CiviCRM project we spent time making sure it was easy to reset the databases so you knew each time what values you were starting with and you always had clean data. I'm thinking I 'll start be creating that logic.
So create a class with methods that does the following
It should be that difficult really, I don't have much of experience with DBTNG, but that's a hurdle for early next year :)
#4
Bumping up this issue.
With the automated testing now available for contrib projects, it'd be a really good opportunity to put some tests into Storm.
#5
I've just committed the first (very simple) test for the Storm Organization module, and have also requested that Stom be part of the beta tests of contrib automated testing so that all patches for Storm are tested.
Hopefully this will be a big advance for the stability as Storm evolves.
There is a really big opportunity here - please can people submit patches that extend this test and/or new tests so that we can get automated testing into Storm!
#6
Each new test can use its own issue.
#7
Automatically closed -- issue fixed for 2 weeks with no activity.