* c. <carlo.defa...@gmail.com> [2012-10-22 12:21]:

New versions of the Forge packages bim (1.1.0) and msh (1.0.5) have been uploaded to the package release forum, and will soon be available for download from Octave-Forge.

[snip]

Thanks for this new release. I noticed a problem in it: the unit testing in the file msh3m_structured_mesh.m does not work. The patch attached below fixes the problem (there were two issues: tests were preceded by "%" instead of "%!" and there were spurious "=" signs after "assert"). However, the test fails with the following error message:

     octave:1> test msh3m_structured_mesh
     ***** test
      x = y = z = linspace (0,1,2);
      [mesh] = msh3m_structured_mesh (x, y, z, 1, 1:6);
      assert (columns (mesh.p), 8);
      assert (columns (mesh.t), 6);
      assert (columns (mesh.e), 12);
     !!!!! test failed
     `p' undefined near line 145 column 10

It seems that several variables (x, y, z, p, and sides) that used inside the subfunction __t6_connections__ are only locally defined in msh3m_structured_mesh.

This bug also affects the bim package.

Rafael







--- octave-msh-1.0.5.orig/inst/msh3m_structured_mesh.m
+++ octave-msh-1.0.5/inst/msh3m_structured_mesh.m
@@ -210,26 +210,26 @@ endfunction
 
 
 %!test
-% x = y = z = linspace (0,1,2)
-% [mesh] = msh3m_structured_mesh (x, y, z, 1, 1:6)
-% assert = (columns (mesh.p), 8)
-% assert = (columns (mesh.t), 6)
-% assert = (columns (mesh.e), 12)
+%! x = y = z = linspace (0,1,2);
+%! [mesh] = msh3m_structured_mesh (x, y, z, 1, 1:6);
+%! assert (columns (mesh.p), 8);
+%! assert (columns (mesh.t), 6);
+%! assert (columns (mesh.e), 12);
 %!test
-% x = y = z = linspace (0,1,3)
-% [mesh] = msh3m_structured_mesh (x, y, z, 1, 1:6)
-% assert = (columns (mesh.p), 27)
-% assert = (columns (mesh.t), 48)
-% assert = (columns (mesh.e), 48)
+%! x = y = z = linspace (0,1,3);
+%! [mesh] = msh3m_structured_mesh (x, y, z, 1, 1:6);
+%! assert (columns (mesh.p), 27);
+%! assert (columns (mesh.t), 48);
+%! assert (columns (mesh.e), 48);
 %!test
-% x = y = z = linspace (0,1,4)
-% [mesh] = msh3m_structured_mesh (x, y, z, 1, 1:6)
-% assert = (columns (mesh.p), 64)
-% assert = (columns (mesh.t), 162)
-% assert = (columns (mesh.e), 108)
+%! x = y = z = linspace (0,1,4);
+%! [mesh] = msh3m_structured_mesh (x, y, z, 1, 1:6);
+%! assert (columns (mesh.p), 64);
+%! assert (columns (mesh.t), 162);
+%! assert (columns (mesh.e), 108);
 %!test
-% x = y = z = linspace (0,1,1)
-% fail([mesh] = msh3m_structured_mesh (x, y, z, 1, 1:6), "warning", "x, y, z cannot be scalar numbers!")
+%! x = y = z = linspace (0,1,1)
+%! fail([mesh] = msh3m_structured_mesh (x, y, z, 1, 1:6), "warning", "x, y, z cannot be scalar numbers!")
 %!test
-% x = y = z = eye(2)
-% fail([mesh] = msh3m_structured_mesh (x, y, z, 1, 1:6),"warning", "x, y, z cannot be matrices!")
\ No newline at end of file
+%! x = y = z = eye(2)
+%! fail([mesh] = msh3m_structured_mesh (x, y, z, 1, 1:6),"warning", "x, y, z cannot be matrices!")
\ No newline at end of file
------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
_______________________________________________
Octave-dev mailing list
Octave-dev@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/octave-dev

Reply via email to