I tried using a separate test class.  However, the Matplotlib test
decorators do not work inside methods so I had to use the current
approach.

This is not a problem with my code, I could not find any examples of these
decorators being used in classes, Matplotlib tests only use methods of they
are not using the decorators.