/[escript]/branches/numpy/escript/test/python/run_xml.py
ViewVC logotype

Diff of /branches/numpy/escript/test/python/run_xml.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2406 by jfenwick, Wed Apr 29 01:37:54 2009 UTC revision 2407 by jfenwick, Fri May 1 01:28:06 2009 UTC
# Line 214  class ParamaterSetTestCase(unittest.Test Line 214  class ParamaterSetTestCase(unittest.Test
214    
215      def testFromDomNumarrayVector(self):      def testFromDomNumarrayVector(self):
216          p3 = ParameterSet()          p3 = ParameterSet()
217          mynumarray = numpy.array([3., 4., 5.], dtype=numpy.float64)          mynumpy = numpy.array([3., 4., 5.], dtype=numpy.float64)
218          p3.declareParameter(numtest=mynumarray)          p3.declareParameter(numtest=mynumpy)
219          doc = self._class(p3)          doc = self._class(p3)
220          assert doc.numtest.dtype == numpy.float64          assert doc.numtest.dtype == numpy.float64
221          assert type(doc.numtest) == numpy.ndarray          assert type(doc.numtest) == numpy.ndarray
222    
223      def testFromDomNumarrayMulti(self):      def testFromDomNumarrayMulti(self):
224          p3 = ParameterSet()          p3 = ParameterSet()
225          mynumarray = numpy.array([[1., 2., 3.], [3., 4., 5.]], dtype=numpy.float64)          mynumpy = numpy.array([[1., 2., 3.], [3., 4., 5.]], dtype=numpy.float64)
226          p3.declareParameter(numtest=mynumarray)          p3.declareParameter(numtest=mynumpy)
227          doc = self._class(p3)          doc = self._class(p3)
228          assert doc.numtest.dtype == numpy.float64          assert doc.numtest.dtype == numpy.float64
229          assert type(doc.numtest) == numpy.ndarray          assert type(doc.numtest) == numpy.ndarray

Legend:
Removed from v.2406  
changed lines
  Added in v.2407

  ViewVC Help
Powered by ViewVC 1.1.26