Don't import test package, too many dependencies.
Had to simplify the check for skimage/matplotlib backend.

It was failing when skimage was present, but not freeimage.