This correction was provided by Geoff Kilpin
More specifically, remove the special case which was making it 4. Fixes #1319.
Autocompletion of people in the admin interface, e.g. at: /admin/hansard/alias/add/ ... was broken. There were two places where ajax_select.js was being loaded, but our manually added inclusion was 404 anyway, so I've removed that. The automatically added inclusion on the other hand, was failing because window.jQuery was undefined, since the while the admin has included jQuery, it's been renamed to django.jQuery. The simplest solution to this is to remove the setting AJAX_SELECT_BOOTSTRAP = False (the default being True). This means that django-ajax-selects will load jQuery and jQuery UI at the versions it requires if they aren't already loaded. This seems to fix #1305 without breaking django-markitup, which was the concern with the previous related change 3f65d0f.
... so don't bother running them from the run-tests scripts; the only tests reported as having been run were doctests that had already been run anyway.
These warnings were just noise in the test output.
The slugify function in django-sluggable would print a warning if passed a str rather than a unicode. Make sure that we create sections from unicode titles in tests.
Presumably when this happens it's an error, but the code doesn't prevent such people from being created at the moment, so update the tests to include such a case to check behaviour when it's present. Also fix the position sorting code to deal with this case.
This is largely based on the work that Matthew Somerville did to get the MapIt tests running on Travis.
We're running a survey on mzalendo.com, so let's have a little banner to encourage people to answer it.
It shouldn't just check that args is empty; it needs to check that it has two or more elements.
As requested by Jessica Musila.
This is a fix for the re-opened #1168. As elsewhere, we don't have proper surname data, so we just assume the last separate word is the last name.
This was a mistake in the earlier rearrangement of the settings modules; PlaceIndex needed to be added to Haystack EXCLUDED_INDEXES in the south_africa module as well as tests_south_africa.
Jessica Musila has asked for these pages only to show: Members of the National Assembly Senators The President i.e. not include Governors or Ward Representatives
This produced confusing output, since stdout and stderr end up mixed. When we're confident this is running correctly, it would be good to instead wrap the running of update_za_hansard.bash in something like: https://github.com/mhl/output-on-error/blob/master/output-on-error
We recommend now that people use the ./run-tests script to run tests, since that will run the non-country-specific tests as well as those specific to each country. However, Duncan Parkes pointed out that lots of people will expect, when new to a project, for "./manage.py test" to run properly. (At the moment it won't because (a) it will try to run country-specific tests and (b) it will try to run tests that depend on particular Django applications even though they may not be in INSTALLED_APPS for the current country. (a) could be worked around pretty easily with nose attributes (-a !country in NOSE_ARGS in base.py) but (b) is more difficult. This commit changes the manage.py script to spot when someone is running ./manage.py test without specifying a settings module, and in that case will make the default settings module pombola.settings.tests, which runs all the non-country-specific tests with an appropriate INSTALLED_APPS.
These settings are now all determined by the COUNTRY_APP, and the value in general.yml is ignored.