Fix some tests

Related to issue #115

This PR takes a stab at fixing some of the easier to fix failing tests.  I'd like to do some refactoring in the tests, but want to get everything passing, first.

On master:
```
Ran 279 tests in 21.879s
FAILED (errors=34, failures=13)

```

On this branch:
```
Ran 278 tests in 21.680s
FAILED (errors=17, failures=8)
```

I (well, my editor) also fixed some whitespace issues.  I can pull that into a separate commit if you'd like - just let me know.