예제 #1
0
 def testPersistence(self):
     """Test that we can round-trip an ValidPolygon through FITS persistence."""
     filename = "testValidPolygon.fits"
     self.polygon.writeFits(filename)
     polygon2 = Polygon.readFits(filename)
     self.assertEqual(self.polygon, polygon2)
     os.remove(filename)
예제 #2
0
 def testPersistence(self):
     """Test that we can round-trip an ValidPolygon through FITS persistence."""
     filename = "testValidPolygon.fits"
     self.polygon.writeFits(filename)
     polygon2 = Polygon.readFits(filename)
     self.assertEqual(self.polygon, polygon2)
     os.remove(filename)
예제 #3
0
 def testReadWrite(self):
     """Test that polygons can be read and written to fits files"""
     for num in range(3, 30):
         poly = self.polygon(num)
         with lsst.utils.tests.getTempFilePath(".fits") as filename:
             poly.writeFits(filename)
             poly2 = Polygon.readFits(filename)
         self.assertEqual(poly, poly2)
예제 #4
0
 def testReadWrite(self):
     """Test that polygons can be read and written to fits files"""
     for num in range(3, 30):
         poly = self.polygon(num)
         filename = 'polygon.fits'
         poly.writeFits(filename)
         poly2 = Polygon.readFits(filename)
         self.assertEqual(poly, poly2)
         os.remove(filename)
예제 #5
0
 def testReadWrite(self):
     """Test that polygons can be read and written to fits files"""
     for num in range(3, 30):
         poly = self.polygon(num)
         filename='polygon.fits'
         poly.writeFits(filename)
         poly2=Polygon.readFits(filename)
         self.assertEqual(poly, poly2)
         os.remove(filename)
예제 #6
0
 def testPersistence(self):
     """Test that we can round-trip an ValidPolygon through FITS persistence."""
     with lsst.utils.tests.getTempFilePath(".fits") as filename:
         self.polygon.writeFits(filename)
         polygon2 = Polygon.readFits(filename)
         self.assertEqual(self.polygon, polygon2)