[jboss-svn-commits] JBL Code SVN: r19259 - labs/jbossrules/trunk/drools-core/src/test/java/org/drools/reteoo.
jboss-svn-commits at lists.jboss.org
jboss-svn-commits at lists.jboss.org
Wed Mar 26 18:58:29 EDT 2008
Author: mark.proctor at jboss.com
Date: 2008-03-26 18:58:29 -0400 (Wed, 26 Mar 2008)
New Revision: 19259
Modified:
labs/jbossrules/trunk/drools-core/src/test/java/org/drools/reteoo/RuleFlowGroupTest.java
Log:
JBRULES-1520 RightTuple merge for asymmetrical Rete propagations
-Fixed RuleFlowGroupTest
Modified: labs/jbossrules/trunk/drools-core/src/test/java/org/drools/reteoo/RuleFlowGroupTest.java
===================================================================
--- labs/jbossrules/trunk/drools-core/src/test/java/org/drools/reteoo/RuleFlowGroupTest.java 2008-03-26 22:56:50 UTC (rev 19258)
+++ labs/jbossrules/trunk/drools-core/src/test/java/org/drools/reteoo/RuleFlowGroupTest.java 2008-03-26 22:58:29 UTC (rev 19259)
@@ -80,8 +80,10 @@
WorkingMemory workingMemory) {
list.add( knowledgeHelper.getRule() );
}
- public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
+ public void readExternal(ObjectInput in) throws IOException,
+ ClassNotFoundException {
+
}
public void writeExternal(ObjectOutput out) throws IOException {
@@ -155,35 +157,35 @@
new ConnectionImpl( start,
Node.CONNECTION_DEFAULT_TYPE,
ruleSet0,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
new ConnectionImpl( ruleSet0,
Node.CONNECTION_DEFAULT_TYPE,
split,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
new ConnectionImpl( split,
Node.CONNECTION_DEFAULT_TYPE,
ruleSet1,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
new ConnectionImpl( split,
Node.CONNECTION_DEFAULT_TYPE,
ruleSet2,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
new ConnectionImpl( ruleSet1,
Node.CONNECTION_DEFAULT_TYPE,
join,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
new ConnectionImpl( ruleSet2,
Node.CONNECTION_DEFAULT_TYPE,
join,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
new ConnectionImpl( join,
Node.CONNECTION_DEFAULT_TYPE,
ruleSet3,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
new ConnectionImpl( ruleSet3,
Node.CONNECTION_DEFAULT_TYPE,
end,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
// process
final RuleFlowProcess process = new RuleFlowProcess();
@@ -209,34 +211,39 @@
final RuleFlowGroupImpl ruleFlowGroup3 = (RuleFlowGroupImpl) agenda.getRuleFlowGroup( "rule-flow-group-3" );
final LeftTuple tuple0 = new LeftTuple( new DefaultFactHandle( 1,
- "cheese" ) );
+ "cheese" ),
+ null );
node0.assertLeftTuple( tuple0,
- context0,
- workingMemory );
+ context0,
+ workingMemory );
final LeftTuple tuple1 = new LeftTuple( new DefaultFactHandle( 1,
- "cheese" ) );
+ "cheese" ),
+ null );
node0.assertLeftTuple( tuple1,
- context0,
- workingMemory );
+ context0,
+ workingMemory );
final LeftTuple tuple2 = new LeftTuple( new DefaultFactHandle( 1,
- "cheese" ) );
+ "cheese" ),
+ null );
node1.assertLeftTuple( tuple2,
- context0,
- workingMemory );
+ context0,
+ workingMemory );
final LeftTuple tuple3 = new LeftTuple( new DefaultFactHandle( 1,
- "cheese" ) );
+ "cheese" ),
+ null );
node2.assertLeftTuple( tuple3,
- context0,
- workingMemory );
+ context0,
+ workingMemory );
final LeftTuple tuple4 = new LeftTuple( new DefaultFactHandle( 1,
- "cheese" ) );
+ "cheese" ),
+ null );
node3.assertLeftTuple( tuple4,
- context0,
- workingMemory );
+ context0,
+ workingMemory );
// RuleFlowGroups should be populated, but the agenda shouldn't
assertEquals( 2,
@@ -339,8 +346,10 @@
WorkingMemory workingMemory) {
list.add( knowledgeHelper.getRule() );
}
- public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
+ public void readExternal(ObjectInput in) throws IOException,
+ ClassNotFoundException {
+
}
public void writeExternal(ObjectOutput out) throws IOException {
@@ -414,35 +423,35 @@
new ConnectionImpl( start,
Node.CONNECTION_DEFAULT_TYPE,
ruleSet0,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
new ConnectionImpl( ruleSet0,
Node.CONNECTION_DEFAULT_TYPE,
split,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
Connection out1 = new ConnectionImpl( split,
Node.CONNECTION_DEFAULT_TYPE,
ruleSet1,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
Connection out2 = new ConnectionImpl( split,
Node.CONNECTION_DEFAULT_TYPE,
ruleSet2,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
new ConnectionImpl( ruleSet1,
Node.CONNECTION_DEFAULT_TYPE,
join,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
new ConnectionImpl( ruleSet2,
Node.CONNECTION_DEFAULT_TYPE,
join,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
new ConnectionImpl( join,
Node.CONNECTION_DEFAULT_TYPE,
ruleSet3,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
new ConnectionImpl( ruleSet3,
Node.CONNECTION_DEFAULT_TYPE,
end,
- Node.CONNECTION_DEFAULT_TYPE);
+ Node.CONNECTION_DEFAULT_TYPE );
ConstraintEvaluator constraint1 = new org.drools.workflow.instance.impl.RuleConstraintEvaluator();
constraint1.setPriority( 1 );
split.setConstraint( out1,
@@ -498,46 +507,53 @@
final RuleFlowGroupImpl ruleFlowGroup3 = (RuleFlowGroupImpl) agenda.getRuleFlowGroup( "rule-flow-group-3" );
final LeftTuple tuple0 = new LeftTuple( new DefaultFactHandle( 1,
- "cheese" ) );
+ "cheese" ),
+ null );
node0.assertLeftTuple( tuple0,
- context0,
- workingMemory );
+ context0,
+ workingMemory );
final LeftTuple tuple1 = new LeftTuple( new DefaultFactHandle( 1,
- "cheese" ) );
+ "cheese" ),
+ null );
node0.assertLeftTuple( tuple1,
- context0,
- workingMemory );
+ context0,
+ workingMemory );
final LeftTuple tuple2 = new LeftTuple( new DefaultFactHandle( 1,
- "cheese" ) );
+ "cheese" ),
+ null );
node1.assertLeftTuple( tuple2,
- context0,
- workingMemory );
+ context0,
+ workingMemory );
final LeftTuple tuple3 = new LeftTuple( new DefaultFactHandle( 1,
- "cheese" ) );
+ "cheese" ),
+ null );
node2.assertLeftTuple( tuple3,
- context0,
- workingMemory );
+ context0,
+ workingMemory );
final LeftTuple tuple4 = new LeftTuple( new DefaultFactHandle( 1,
- "cheese" ) );
+ "cheese" ),
+ null );
node3.assertLeftTuple( tuple4,
- context0,
- workingMemory );
+ context0,
+ workingMemory );
final LeftTuple splitTuple1 = new LeftTuple( new DefaultFactHandle( 1,
- "cheese" ) );
+ "cheese" ),
+ null );
splitNode1.assertLeftTuple( splitTuple1,
- context0,
- workingMemory );
+ context0,
+ workingMemory );
final LeftTuple splitTuple2 = new LeftTuple( new DefaultFactHandle( 1,
- "cheese" ) );
+ "cheese" ),
+ null );
splitNode2.assertLeftTuple( splitTuple2,
- context0,
- workingMemory );
+ context0,
+ workingMemory );
final RuleFlowGroupImpl systemRuleFlowGroup = (RuleFlowGroupImpl) agenda.getRuleFlowGroup( "DROOLS_SYSTEM" );
More information about the jboss-svn-commits
mailing list