1. Vincent Fiack
  2. blocks

Commits

Vincent Fiack  committed eed1c34

filter was forgotten in the functional.blocks unittest

  • Participants
  • Parent commits ece5c68
  • Branches default

Comments (0)

Files changed (2)

File blocks-tests/src/test/blocks/functional.blocks

View file
  • Ignore whitespace
     <call blockId="core.Declare">
       <param variable="" value="filtered" name="varname" type="text"/>
       <callparam name="value" type="other">
-        <call blockId="functional.Map">
-          <param variable="afterMap" value="" name="list" type="other"/>
+        <call blockId="functional.Filter">
+          <param variable="afterMap" name="list" type="other"/>
           <blockparam name="block" type="block">
             <block>
               <code>
                 <call blockId="integer.IsGreaterThan">
                   <param variable="elem" name="left" type="integer"/>
-                  <param variable="" value="10" name="right" type="integer"/>
+                  <param value="10" name="right" type="integer"/>
                 </call>
               </code>
               <slots/>
     <call blockId="core.PrintLine">
       <callparam name="message" type="text">
         <call blockId="text.ApplyTemplate">
-          <param value="${myList} => (x2) ${afterMap} => (&gt;10) ${filtered}" name="template" type="text"/>
+          <param value="${myList} =&gt; (x2) ${afterMap} =&gt; (&gt;10) ${filtered}" name="template" type="text"/>
         </call>
       </callparam>
     </call>

File blocks-tests/src/test/java/org/blocks/tests/BlocksTest.java

View file
  • Ignore whitespace
         suite.addTest(test);
 
         test = new BlocksTestCase(new File(directory, "functional.blocks"));
-        test.expectedPrintln("[1, 3, 5, 7, 9] => (x2) [2, 6, 10, 14, 18] => (>10) [false, false, false, true, true]");
+        test.expectedPrintln("[1, 3, 5, 7, 9] => (x2) [2, 6, 10, 14, 18] => (>10) [14, 18]");
 
         suite.addTest(test);