Use InstanceTestCase from django-subdomain-instances.

There is no need for SayIt to have its own version of
InstanceTestCase if the django-subdomain-instances one
takes options for the default instance that's created.
A bit of PEP8 for helpers.py
Override MEDIA_ROOT as well as MEDIA_URL.

This has two desirable effects:

1) The files created by the tests are in a temp directory which is
deleted at the end, so don't end up cluttering up the real MEDIA_ROOT
directory.

This could be done better with a context manager - probably in a class
decorator, but the temporary directory should be deleted unless things
go wrong.

2) FileSystemStorage keeps its own copy of MEDIA_URL, so
override_settings(MEDIA_URL=...) doesn't make all the tests pass all
the time - exactly which ones fail and when seems to vary depending on
the system.
Add OpenGraph data and tests.

Add Opengraph data to the base template, so it appears on every page.
In particular, tailor it to
* instance home pages
* speaker detail pages
* speech detail pages
* section detail pages

Allow testing of OG keys against regular expressions or strings.

A dictionary of OG keys to tests can be passed in to a utility
function for testing the OpenGraph data at a URL. The keys are
OpenGraph keys without the initial 'og:', the values are either
strings of the expected output or regular expressions which must
be found in the expected output by searching.

Additionally any OG key which should contain a URL is checked to
make sure the URL is absolute.
Skip tests which need override_settings(MEDIA_ROOT) in Django 1.4.

override_settings(MEDIA_ROOT) isn't made to sort out FileSystemStorage
until Django 1.5: (https://github.com/django/django/commit/a24ffa52d029)
so let's skip tests that need that in 1.4.

In speaker_tests, instead of skipping the whole test, which does other
useful stuff, I've just put an if around an assertion.
Merge branch 'issues/364-more-opengraph-data_over_subdomains_testcase'
Set Travis CFLAGS to disable compiler optimisation

The lxml install script recommends this to speed up its installation.
A variety of flake8 fixes.

F401 module imported but unused
F812 list comprehension redefines variable
F821 undefined name
F841 local variable assigned to but never used
E711 comparison to None should be ‘if cond is None:’
E713 test for membership should be ‘not in’
General Popolo json import script.

Rewrite and merge the Popolo json import scripts from SayIt Philadelphia
and OpenNorth to make a more general Popolo json import script which
works in an 'upsert' manner.

It should now update any existing entries and associated records, rather
than delete/recreate the identifiers/other names/etc. Also fix a number
of bugs.
Break popolo importer out of management command.

Break the Popolo importer out of the management command so we
can use it from the web frontend too.

The importer can now be created with an instance to import
stuff into, and this can be passed in from the management command.

It's also been updated to work with a single file or unpaginated output
like

http://scrapers-ruby.herokuapp.com/organizations

Some extra python packages are needed in order to download from Popit
using requests.
Only import persons.

Currently, persons are the only objects from popolo that sayit
uses, and they are imported as speeches.Speaker objects, which
are popolo.Person objects which are subdomain instance aware.

Rather than making instance aware versions of the other Popolo
object types, for the moment we're going to import only the
Persons.
Add view for importing persons from Popolo.

This page still needs linking in from somewhere.
Add some basic alert box CSS.
Placate flake8.
Work around Django <= 1.5 generic relations problem.

The ORM changed significantly between Django 1.5 and 1.6, changing
the way filters and therefore get_or_create work over generic relations.

http://stackoverflow.com/questions/22200791/django-generic-foreign-key-filtering-difference-between-v1-5-v1-6

This nasty hackery gets the Popolo importer working with Django 1.4.
I'm looking forward to removing it again when support for 1.4 is
dropped.
Add link to speaker import on speaker list page.
Delete repeated test class.
Use requests in import_akomantoso.

Also refactor tests slightly to remove duplication.
Add at AN import page.

Add AN import page, which consists of a box to put your source
url in and the option to skip/clobber/duplicate sections.
Only ask about existing sections if there are some.