RF: refactor nifti1 / analyze + tests for nifti2

Put tests into classes and generalize class names and constants ready
for implementing nifti2.