mirror of
https://github.com/kestra-io/kestra.git
synced 2025-12-19 18:05:41 -05:00
fix(tests): fix allValidTypedInputs() test by avoiding serialization of strings or other scalars, only serialize Maps and Collections
This commit is contained in:
committed by
Loïc Mathieu
parent
f3aed38964
commit
a74ebd5cd6
@@ -500,7 +500,14 @@ public class FlowInputOutput {
|
||||
}
|
||||
case JSON -> JacksonMapper.toObject(current.toString());
|
||||
case YAML -> {
|
||||
String yaml = YAML_MAPPER.writeValueAsString(current);
|
||||
String yaml;
|
||||
if(current instanceof Collection<?> || current instanceof Map){
|
||||
yaml = YAML_MAPPER.writeValueAsString(current);
|
||||
}
|
||||
else{
|
||||
yaml = current.toString();
|
||||
}
|
||||
|
||||
yield YAML_MAPPER.readValue(yaml, JacksonMapper.OBJECT_TYPE_REFERENCE);
|
||||
}
|
||||
case URI -> {
|
||||
|
||||
Reference in New Issue
Block a user