/[fenfire]/fenfire/org/fenfire/functional/superfunctional1.test
ViewVC logotype

Diff of /fenfire/org/fenfire/functional/superfunctional1.test

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

revision 1.1 by tjl, Wed Sep 10 13:00:46 2003 UTC revision 1.2 by tjl, Mon Sep 15 17:34:44 2003 UTC
# Line 143  def testSuperlazy2_graphtwid(): Line 143  def testSuperlazy2_graphtwid():
143      seteq( f.f(nodes[0]) , [nodes[3]] )      seteq( f.f(nodes[0]) , [nodes[3]] )
144    
145    
146    def testSuperlazy3_doublecache_chg():
147        """Test that a double cache works right.
148    
149        There used to be a bug where the entries in the smaller cache
150        didn't chg() to the lower cache correctly.
151        """
152        background = vob.util.ExplicitBackground()
153        graph = ff.swamp.impl.HashGraph()
154        functional = ff.functional.SuperFunctional1(graph, background)
155    
156        # Two normal caches
157        functional.cache("A", 2, 0)
158        functional.cache("B", 100, 0)
159    
160        nodes = [ff.swamp.Nodes.N() for i in range(0,10)]
161    
162        node = functional.createFunctionInstance(
163                "A",
164                ff.functional.FunctionalTest.TripleSet_Node,
165                [ nodes[1] ]
166                )
167        node = functional.createFunctionInstance(
168                "B",
169                ff.functional.FunctionalTest.Identity_Node,
170                [ node ]
171                )
172        f = node.getCallableFunction()
173    
174        # The latest one has to be the one to move
175        for i in range(2, 7):
176            seteq( f.f(nodes[i]) , [] )
177    
178        for i in range(2, 7):
179            graph.add(nodes[i], nodes[1], nodes[0])
180    
181        for i in range(2, 7):
182            seteq( f.f(nodes[i]) , [nodes[0]] )
183    
184    
185    
186    

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26