should be much simpler if you use assert_throws (here and in all other tests that check for an exception).  See http://darobin.github.io/test-harness-tutorial/docs/using-testharness.html