Skip to content

Commit c5ced45

Browse files
committed
docs; renaming multiply3
Signed-off-by: Teo Koon Peng <[email protected]>
1 parent bf63e5b commit c5ced45

File tree

8 files changed

+35
-33
lines changed

8 files changed

+35
-33
lines changed

src/diagram.rs

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -468,7 +468,7 @@ mod tests {
468468
},
469469
"op1": {
470470
"type": "node",
471-
"builder": "multiply3",
471+
"builder": "multiply3_uncloneable",
472472
"next": "dispose",
473473
},
474474
"dispose": {
@@ -500,7 +500,7 @@ mod tests {
500500
"ops": {
501501
"op1": {
502502
"type": "node",
503-
"builder": "multiply3",
503+
"builder": "multiply3_uncloneable",
504504
"next": "terminate",
505505
},
506506
"terminate": {
@@ -536,7 +536,7 @@ mod tests {
536536
},
537537
"op1": {
538538
"type": "node",
539-
"builder": "multiply3_cloneable",
539+
"builder": "multiply3",
540540
"next": "fork_clone",
541541
},
542542
"fork_clone": {
@@ -618,7 +618,7 @@ mod tests {
618618
},
619619
"op1": {
620620
"type": "node",
621-
"builder": "multiply3",
621+
"builder": "multiply3_uncloneable",
622622
"next": "op2",
623623
},
624624
"op2": {
@@ -649,12 +649,12 @@ mod tests {
649649
},
650650
"op1": {
651651
"type": "node",
652-
"builder": "multiply3",
652+
"builder": "multiply3_uncloneable",
653653
"next": "op2",
654654
},
655655
"op2": {
656656
"type": "node",
657-
"builder": "multiply3",
657+
"builder": "multiply3_uncloneable",
658658
"next": "op1",
659659
},
660660
"terminate": {
@@ -685,7 +685,7 @@ mod tests {
685685
},
686686
"op1": {
687687
"type": "node",
688-
"builder": "multiply3_cloneable",
688+
"builder": "multiply3",
689689
"next": "fork_clone",
690690
},
691691
"fork_clone": {
@@ -694,7 +694,7 @@ mod tests {
694694
},
695695
"op2": {
696696
"type": "node",
697-
"builder": "multiply3",
697+
"builder": "multiply3_uncloneable",
698698
"next": "terminate",
699699
},
700700
"terminate": {
@@ -742,9 +742,9 @@ mod tests {
742742
"ops": {
743743
"start": {
744744
"type": "start",
745-
"next": "multiply3"
745+
"next": "multiply3_uncloneable"
746746
},
747-
"multiply3": {
747+
"multiply3_uncloneable": {
748748
"type": "node",
749749
"builder": "multiplyBy",
750750
"config": 7,

src/diagram/fork_clone.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ mod tests {
8383
},
8484
"op1": {
8585
"type": "node",
86-
"builder": "multiply3",
86+
"builder": "multiply3_uncloneable",
8787
"next": "fork_clone"
8888
},
8989
"fork_clone": {
@@ -92,7 +92,7 @@ mod tests {
9292
},
9393
"op2": {
9494
"type": "node",
95-
"builder": "multiply3",
95+
"builder": "multiply3_uncloneable",
9696
"next": "terminate"
9797
},
9898
"terminate": {
@@ -117,7 +117,7 @@ mod tests {
117117
},
118118
"op1": {
119119
"type": "node",
120-
"builder": "multiply3_cloneable",
120+
"builder": "multiply3",
121121
"next": "fork_clone"
122122
},
123123
"fork_clone": {
@@ -126,7 +126,7 @@ mod tests {
126126
},
127127
"op2": {
128128
"type": "node",
129-
"builder": "multiply3_cloneable",
129+
"builder": "multiply3",
130130
"next": "terminate"
131131
},
132132
"terminate": {

src/diagram/impls.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
/// A struct to provide the default implementation for various operations.
12
pub struct DefaultImpl;
23

4+
/// A struct to provide "not supported" implementations for various operations.
35
pub struct NotSupported;

src/diagram/join.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ mod tests {
117117
},
118118
"op1": {
119119
"type": "node",
120-
"builder": "multiply3",
120+
"builder": "multiply3_uncloneable",
121121
"next": "join",
122122
},
123123
"getSplitValue2": {
@@ -127,7 +127,7 @@ mod tests {
127127
},
128128
"op2": {
129129
"type": "node",
130-
"builder": "multiply3",
130+
"builder": "multiply3_uncloneable",
131131
"next": "join",
132132
},
133133
"join": {

src/diagram/node_registry.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -674,11 +674,11 @@ mod tests {
674674
fn test_register_node_builder() {
675675
let mut registry = NodeRegistry::default();
676676
registry.register_node_builder(
677-
"multiply3".to_string(),
677+
"multiply3_uncloneable".to_string(),
678678
"Test Name".to_string(),
679679
|builder, _config: ()| builder.create_map_block(multiply3),
680680
);
681-
let registration = registry.get_registration("multiply3").unwrap();
681+
let registration = registry.get_registration("multiply3_uncloneable").unwrap();
682682
assert!(registration.metadata.request.deserializable);
683683
assert!(registration.metadata.response.serializable);
684684
assert!(!registration.metadata.response.cloneable);
@@ -692,11 +692,11 @@ mod tests {
692692
.registration_builder()
693693
.with_response_cloneable()
694694
.register_node_builder(
695-
"multiply3".to_string(),
695+
"multiply3_uncloneable".to_string(),
696696
"Test Name".to_string(),
697697
|builder, _config: ()| builder.create_map_block(multiply3),
698698
);
699-
let registration = registry.get_registration("multiply3").unwrap();
699+
let registration = registry.get_registration("multiply3_uncloneable").unwrap();
700700
assert!(registration.metadata.request.deserializable);
701701
assert!(registration.metadata.response.serializable);
702702
assert!(registration.metadata.response.cloneable);
@@ -711,11 +711,11 @@ mod tests {
711711
.registration_builder()
712712
.with_unzippable()
713713
.register_node_builder(
714-
"multiply3".to_string(),
714+
"multiply3_uncloneable".to_string(),
715715
"Test Name".to_string(),
716716
move |builder: &mut Builder, _config: ()| builder.create_map_block(tuple_resp),
717717
);
718-
let registration = registry.get_registration("multiply3").unwrap();
718+
let registration = registry.get_registration("multiply3_uncloneable").unwrap();
719719
assert!(registration.metadata.request.deserializable);
720720
assert!(registration.metadata.response.serializable);
721721
assert!(!registration.metadata.response.cloneable);

src/diagram/testing.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,16 +85,16 @@ fn opaque_response(_: i64) -> Unserializable {
8585
fn new_registry_with_basic_nodes() -> NodeRegistry {
8686
let mut registry = NodeRegistry::default();
8787
registry.register_node_builder(
88-
"multiply3".to_string(),
89-
"multiply3".to_string(),
88+
"multiply3_uncloneable".to_string(),
89+
"multiply3_uncloneable".to_string(),
9090
|builder: &mut Builder, _config: ()| builder.create_map_block(multiply3),
9191
);
9292
registry
9393
.registration_builder()
9494
.with_response_cloneable()
9595
.register_node_builder(
96-
"multiply3_cloneable".to_string(),
97-
"multiply3_cloneable".to_string(),
96+
"multiply3".to_string(),
97+
"multiply3".to_string(),
9898
|builder: &mut Builder, _config: ()| builder.create_map_block(multiply3),
9999
);
100100
registry

src/diagram/transform.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ mod tests {
9191
},
9292
"op1": {
9393
"type": "node",
94-
"builder": "multiply3",
94+
"builder": "multiply3_uncloneable",
9595
"next": "transform",
9696
},
9797
"transform": {

src/diagram/unzip.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ mod tests {
112112
(
113113
"op_1".to_string(),
114114
DiagramOperation::Node(NodeOp {
115-
builder: "multiply3".to_string(),
115+
builder: "multiply3_uncloneable".to_string(),
116116
config: serde_json::Value::Null,
117117
next: "unzip".to_string(),
118118
}),
@@ -163,23 +163,23 @@ mod tests {
163163
(
164164
"op_2".to_string(),
165165
DiagramOperation::Node(NodeOp {
166-
builder: "multiply3".to_string(),
166+
builder: "multiply3_uncloneable".to_string(),
167167
config: serde_json::Value::Null,
168168
next: "terminate".to_string(),
169169
}),
170170
),
171171
(
172172
"op_3".to_string(),
173173
DiagramOperation::Node(NodeOp {
174-
builder: "multiply3".to_string(),
174+
builder: "multiply3_uncloneable".to_string(),
175175
config: serde_json::Value::Null,
176176
next: "terminate".to_string(),
177177
}),
178178
),
179179
(
180180
"op_4".to_string(),
181181
DiagramOperation::Node(NodeOp {
182-
builder: "multiply3".to_string(),
182+
builder: "multiply3_uncloneable".to_string(),
183183
config: serde_json::Value::Null,
184184
next: "terminate".to_string(),
185185
}),
@@ -256,7 +256,7 @@ mod tests {
256256
},
257257
"op2": {
258258
"type": "node",
259-
"builder": "multiply3",
259+
"builder": "multiply3_uncloneable",
260260
"next": "terminate",
261261
},
262262
"terminate": {
@@ -296,7 +296,7 @@ mod tests {
296296
},
297297
"op2": {
298298
"type": "node",
299-
"builder": "multiply3",
299+
"builder": "multiply3_uncloneable",
300300
"next": "terminate",
301301
},
302302
"terminate": {

0 commit comments

Comments
 (0)