Changeset 8d6440f in sasview for DataLoader/test
- Timestamp:
- Jul 9, 2008 6:05:49 PM (16 years ago)
- Branches:
- master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- c45976b
- Parents:
- 8dac49d
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
DataLoader/test/testLoad.py
r94daf8a r8d6440f 104 104 data=self.L.load('MP_New.sans') 105 105 106 self.assertEqual(data. __class__,danse_reader.ReaderInfo)106 self.assertEqual(data.wavelength,7.5) 107 107 108 108 #tested corrupted file.sans … … 112 112 logging.error(str(msg)) 113 113 #else: raise ValueError,"No error raised for missing extension" 114 114 115 def testload5(self): 115 116 """ Testing loading image file""" 116 117 data=self.L.load('angles_flat.png') 117 self.assertEqual(data. __class__,tiff_reader.ReaderInfo)118 self.assertEqual(data.xbins ,200) 118 119 119 120 def testload6(self): 120 121 """test file with unknown extension""" 121 122 try:self.L.load('hello.missing') 122 except ValueError,msg:123 except RuntimeError,msg: 123 124 self.assertEqual( str(msg),"Unknown file type '.missing'") 124 125 else: raise ValueError,"No error raised for missing extension" … … 126 127 #self.L.lookup('hello.missing') 127 128 try: self.L.lookup('hello.missing') 128 except ValueError,msg:129 except RuntimeError,msg: 129 130 self.assertEqual( str(msg),"Unknown file type '.missing'") 130 131 else: raise ValueError,"No error raised for missing extension"
Note: See TracChangeset
for help on using the changeset viewer.