source: sasview/DataLoader/test/utest_ascii.py @ 7b64d95

ESS_GUIESS_GUI_DocsESS_GUI_batch_fittingESS_GUI_bumps_abstractionESS_GUI_iss1116ESS_GUI_iss879ESS_GUI_iss959ESS_GUI_openclESS_GUI_orderingESS_GUI_sync_sascalccostrafo411magnetic_scattrelease-4.1.1release-4.1.2release-4.2.2release_4.0.1ticket-1009ticket-1094-headlessticket-1242-2d-resolutionticket-1243ticket-1249ticket885unittest-saveload
Last change on this file since 7b64d95 was 7b64d95, checked in by Mathieu Doucet <doucetm@…>, 15 years ago

Unit test for new ascii reader implementation

  • Property mode set to 100644
File size: 570 bytes
Line 
1"""
2    Unit tests for the ascii (n-column) reader
3"""
4import warnings
5warnings.simplefilter("ignore")
6
7import unittest
8from DataLoader.loader import  Loader
9 
10import os.path
11
12class abs_reader(unittest.TestCase):
13   
14    def setUp(self):
15        self.loader = Loader()
16       
17    def test_checkdata(self):
18        # Test .ABS file loaded as ascii
19        f = self.loader.load("ascii_test_1.txt")
20        # The length of the data is 10
21        self.assertEqual(len(f.x), 10)
22       
23       
24if __name__ == '__main__':
25    unittest.main()
26   
Note: See TracBrowser for help on using the repository browser.