[Review]: Test map sources (#664)

I'll be adding tests to classes in map/sources in this PR (issue #664 ). What I have now is by no means the final result, and more stuff will be added in due time.
This is going to be one long PR!
You should use the numpy floating point comparison functions to test
floating point equality
On Jun 7, 2014 8:02 AM, "Pritish Chakraborty" <notifications@github.com>
wrote:

> In sunpy/map/sources/tests/test_xrt_source.py:
>
> > +def test_measurement():
> > +    """Tests the measurement property of the XRTMap object."""
> > +    assert xrt.measurement == ""
> > +
> > +def test_normalizer():
> > +    """Tests the creation of the Normalizer object,
> > +    as well as its properties."""
> > +    norm = xrt._get_mpl_normalizer()
> > +    if xrt.data.dtype == np.uint8:
> > +        assert norm is None
> > +    else:
> > +        assert isinstance(norm, colors.Normalize)
> > +        assert norm.vmin == (max(0, xrt.mean() - 3 * xrt.std()))
> > +        assert norm.vmax == (min(xrt.max(), xrt.mean() + 3 * xrt.std()))
> > +	#assert norm.vmin == 0 # Max of 0 and -9.6202650635081
> > +	#assert norm.vmax == 581.56145769046122 # Min of 4095 and 581.56145769046122
>
> You mean 'commented'? Those asserts cause problems on Travis. I guess the
> floating point values differ slightly and are never exactly the same. It
> was @dpshelio <https://github.com/dpshelio> 's idea that I should compute
> the values first and test against those (rightly so). The commented asserts
> you see are a result of that idea. But it doesn't seem to cut it in this
> case, and hence I commented them out.
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/sunpy/sunpy/pull/941/files#r13519345>.
>