diff --git a/test_absorber.py b/test_absorber.py index 587664cae..3425ec943 100644 --- a/test_absorber.py +++ b/test_absorber.py @@ -159,6 +159,7 @@ def propagate_to_target(self, branch): def propagate_wrapper_to_target(self, branch): if branch["connections"][-1] == self.inl[0]: + branch["components"] += [self] return if self in branch["components"]: diff --git a/test_desorber.py b/test_desorber.py index 904a092b6..152f159d3 100644 --- a/test_desorber.py +++ b/test_desorber.py @@ -91,7 +91,7 @@ def fluid_deriv(self, increment_filter, k): def pressure_equality_func(self): residual = [] - for c in self.outl : + for c in self.outl: residual += [c.p.val_SI - self.inl[0].p.val_SI] return residual @@ -163,14 +163,16 @@ def start_branch(self): return branches def start_fluid_wrapper_branch(self): - outconn = self.outl[0] - branch = { - "connections": [outconn], - "components": [self] - } - outconn.target.propagate_wrapper_to_target(branch) + branches = {} + for outconn in self.outl: + branch = { + "connections": [outconn], + "components": [self] + } + outconn.target.propagate_wrapper_to_target(branch) + branches[outconn.label] = branch - return {outconn.label: branch} + return branches def propagate_to_target(self, branch): return