Factor out sidebar entry construction
This makes it possible to reuse this logic in other modules as well,
preventing code duplication. While at it, move additional_sidebar
merging before the other entries (additional entries should go first,
since the other entries are mostly dev-only etc).
Patch by: Sverre Rabbelier
#!/bin/sh
NOSE_WITH_DOCTEST=t
export NOSE_WITH_DOCTEST
NOSE_DOCTEST_EXTENSION=txt
export NOSE_DOCTEST_EXTENSION
#NOSE_DETAILED_ERRORS=t
#export NOSE_DETAILED_ERRORS
nosetests $*