Yes, we need a better testing system. I have also never known how to run them.
I see John writes: runtests.sh fails lots
but I don't have a runtests.sh file on my computer.

I would like a system where

import gramps
gramps.tests()

just runs all the tests, or for the gramps pacakge:

gramps --test

Doing test should then run all scripts in the testsuite (like http://docs.python.org/library/unittest.html )

Benny

2012/5/28 Doug Blank <doug.blank@gmail.com>
On Mon, May 28, 2012 at 3:57 PM, John Ralls <jralls@ceridwen.us> wrote:
>
> On May 28, 2012, at 11:56 AM, Nick Hall wrote:
>
>> John,
>>
>> Thanks for letting me know about these problems.
>>
>> On 28/05/12 18:53, John Ralls wrote:
>>> On Debian Wheezy:
>>> With `./setup.py build`:
>>> copying src/DbState.py ->  build/lib.linux-i686-2.7/gramps
>>> error: package directory 'src/DateHandler' does not exist
>>
>> Yes, distutils is experimental and it hasn't been updated since I started the work on GEPS008.  When I have finished the GEPS008 work, I will continue helping Rob with GEPS026 again.
>>
>>
>>>
>>> Building with autotools completes without errors.
>>
>> I am keeping autotools up-to-date.
>>
>>
>>>
>>> runtests.sh fails lots of tests because it can't find favicon.ico:
>>> IOError: [Errno 2] No such file or directory: u'/home/john/gramps-svn/src/images/favicon.ico'
>>>
>>> (It has been moved to plugins/webstuff/images.)
>>>
>>> RunAllTests.py just fails with
>>> Traceback (most recent call last):
>>>   File "../test/RunAllTests.py", line 113, in<module>
>>>     unittest.TextTestRunner(verbosity=options.verbose_level).run(allTheTests())
>>>   File "../test/RunAllTests.py", line 76, in allTheTests
>>>     return unittest.TestSuite(getTestSuites()[0])
>>>   File "../test/RunAllTests.py", line 73, in getTestSuites
>>>     return (test_suites,perf_suites)
>>> UnboundLocalError: local variable 'test_suites' referenced before assignment
>>>
>>> but that's perhaps a separate issue not related to moving the files around.
>>
>> The src/images directory is on my ToDo list, but I haven't looked at it yet.
>>
>> The directories that I have re-structured so far contain the filter, datehandler and merge code.
>>
>> I am currently working on the GrampsLogger directory and removing the Assistant.py code, but I haven't committed this yet.
>
> Looks like the favicon.ico bust is from a change Doug made almost 2 years ago. It would appear that nobody is actually running the tests. :-(

It looks like someone is :-)

Can you give a refresher on what you did to run the tests? It seems
that there are a few tests sprinkled throughout.

-Doug

> Regards,
> John Ralls
>
>
> ------------------------------------------------------------------------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and
> threat landscape has changed and how IT managers can respond. Discussions
> will include endpoint security, mobile security and the latest in malware
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
> _______________________________________________
> Gramps-devel mailing list
> Gramps-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gramps-devel

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Gramps-devel mailing list
Gramps-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gramps-devel