Changeset 3ee0451 in sasview for test/sasdataloader
- Timestamp:
- Feb 14, 2018 1:41:43 PM (7 years ago)
- Branches:
- master, magnetic_scatt, release-4.2.2, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, unittest-saveload
- Children:
- 425feff
- Parents:
- c36c09f
- Location:
- test/sasdataloader/test
- Files:
-
- 1 added
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
test/sasdataloader/test/utest_generic_file_reader_class.py
rf53d684 r3ee0451 9 9 10 10 from sas.sascalc.dataloader.data_info import DataInfo, plottable_1D 11 from sas.sascalc.dataloader.loader import Loader 11 12 from sas.sascalc.dataloader.file_reader_base_class import FileReader 12 13 … … 24 25 self.bad_file = find("ACB123.txt") 25 26 self.good_file = find("123ABC.txt") 27 self.generic_reader = Loader() 28 self.deprecated_file_type = find("FEB18012.ASC") 26 29 27 30 def test_bad_file_path(self): … … 36 39 self.assertEqual(len(output), 1) 37 40 self.assertEqual(output[0].meta_data["blah"], '123ABC exists!') 41 42 def test_old_file_types(self): 43 f = self.generic_reader.load(self.deprecated_file_type) 44 last_f = f[0] 45 if hasattr(last_f, "errors"): 46 self.assertEquals(len(last_f.errors), 1) 47 else: 48 self.fail("Errors did not propogate to the file properly.") 38 49 39 50 def tearDown(self):
Note: See TracChangeset
for help on using the changeset viewer.