Django 1.7 support

* (Tests) MIDDLEWARE_CLASSES set, to remove Django 1.7 warning
* (Tests) Added an exception test case
* Django 1.7 no longer has ConstantIncludeNode, updated _scan_node() to work.