Fix list comprehension bug

List comprehension during isinstance check caused assertion error.
Testing for ModelExtension
Added a new directory 'tests' in model_extensions.
Added a script t test that Model accepts a list of ModelExtension instances.
pep8 fixes
Add file module-level docstring
Merge pull request #999 from woodshop/extensions_fix

Fix list comprehension bug