From ce3d5e864acefbdb73264a114814d78c2ed5abb1 Mon Sep 17 00:00:00 2001 From: Jusong Yu Date: Mon, 2 Dec 2024 09:38:29 +0100 Subject: [PATCH] Remove duplicate codes --- tests/test_expose.py | 36 ------------------------------------ 1 file changed, 36 deletions(-) diff --git a/tests/test_expose.py b/tests/test_expose.py index f48ce32e..0f6f8087 100644 --- a/tests/test_expose.py +++ b/tests/test_expose.py @@ -8,42 +8,6 @@ from plumpy.processes import Process -def validator_function(input, port): - pass - - -class BaseNamespaceProcess(NewLoopProcess): - @classmethod - def define(cls, spec): - super().define(spec) - spec.input('top') - spec.input('namespace.sub_one') - spec.input('namespace.sub_two') - spec.inputs['namespace'].valid_type = (int, float) - spec.inputs['namespace'].validator = validator_function - - -class BaseProcess(NewLoopProcess): - @classmethod - def define(cls, spec): - super().define(spec) - spec.input('a', valid_type=str, default='a') - spec.input('b', valid_type=str, default='b') - spec.inputs.dynamic = True - spec.inputs.valid_type = str - - -class ExposeProcess(NewLoopProcess): - @classmethod - def define(cls, spec): - super().define(spec) - spec.expose_inputs(BaseProcess, namespace='base.name.space') - spec.input('c', valid_type=int, default=1) - spec.input('d', valid_type=int, default=2) - spec.inputs.dynamic = True - spec.inputs.valid_type = int - - def validator_function(input, port): pass