/[ascend]/trunk/pygtk/test.py
ViewVC logotype

Contents of /trunk/pygtk/test.py

Parent Directory Parent Directory | Revision Log Revision Log


Revision 933 - (show annotations) (download) (as text)
Thu Nov 23 22:28:00 2006 UTC (13 years, 10 months ago) by johnpye
File MIME type: text/x-python
File size: 847 byte(s)
Fixed some bugs with error_reporter_tree, and with error_callback in gtkbrowser.py
1 import unittest
2
3 class AscendTest(unittest.TestCase):
4
5 def setUp(self):
6 import ascpy
7 self.L = ascpy.Library()
8
9 def tearDown(self):
10 self.L.clear()
11 del self.L
12
13 def testIDA(self):
14 try:
15 self.L.load('johnpye/shm.a4c')
16 M = self.L.findType('shm').getSimulation('sim')
17 M.solve(ascpy.Solver("QRSlv"),ascpy.SolverReporter())
18 except Exception,e:
19 self.fail(str(e))
20
21 def testloading(self):
22 pass
23
24 def testsystema4l(self):
25 self.L.load('simpleflowsheet01.a4c')
26
27 def testatomsa4l(self):
28 self.L.load('atoms.a4l')
29
30 def testlog10(self):
31 self.L.load('johnpye/testlog10.a4c')
32 T = self.L.findType('testlog10')
33 M = T.getSimulation('sim')
34 M.solve(ascpy.Solver("QRSlv"),ascpy.SolverReporter())
35 M.run(T.getMethod('self_test'))
36
37 class NotToBeTested:
38 def nothing(self):
39 pass
40
41
42 if __name__=='__main__':
43 unittest.main()

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22