from __future__ import absolute_import
from __future__ import print_function
from casatasks.private.casa_transition import is_CASA6
from casatasks import plotprofilemap
from casatasks import exportfits
from casatools import image
from casatools import regionmanager
from casatools import ctsys
datapath = ctsys.resolve('unittest/plotprofilemap/')
from __main__ import default
from tasks import plotprofilemap
from tasks import exportfits
from taskinit import iatool as image
from taskinit import rgtool as regionmanager
datapath = os.environ.get('CASAPATH').split()[0] + '/casatestdata/unittest/plotprofilemap/'
class plotprofilemap_test(unittest.TestCase):
This is a test suite for plotprofilemap task.
test_image_not_exist: input image does not exist (causes error)
test_not_overwrite: output image already exists (causes error)
test_pol_not_out_of_range: pol index is out of range (causes error)
test_plotmasked_invalid: unsupported plotmasked value (causes error)
test_numpanel_5x5: standard test (5x5 panels)
test_numpanel_10x10: standard test (10x10 panels)
test_plotmasked_empty: plotmasked is empty
test_plotmasked_zero: plotmasked is zero
test_plotmasked_text: plotmasked is text
test_plotmasked_plot: plotmasked is plot
test_plotmasked_none: plotmasked is none
test_export_image: test export the plot to PNG file
test_fits_image: input image is FITS cube
test_title: put title to the plot
imagename_ref = 'expected.im'
prefix = 'plotprofilemap_test'
imagename = prefix + '.im'
fitsimage = prefix + '.fits'