Github user MikeThomsen commented on a diff in the pull request: https://github.com/apache/nifi/pull/2672#discussion_r187481205 --- Diff: nifi-mock/src/main/java/org/apache/nifi/util/MockPropertyValue.java --- @@ -202,6 +203,9 @@ public PropertyValue evaluateAttributeExpressions(final AttributeValueDecorator @Override public PropertyValue evaluateAttributeExpressions(final FlowFile flowFile) throws ProcessException { + if (flowFile == null) { --- End diff -- > This feels a little bit odd to me, as it's very unclear just from looking at this method what the intent is here The intent is to mirror the behavior of running NiFi when you pass a null flowfile object into `evaluateExpressionLanguage(FlowFile)`. This works on a running processor: ``` FlowFile parent = null; String charset = context.getProperty(CHARSET).evaluateAttributeExpressions(parent).getValue(); ``` it does not work against the testing framework. So it seems natural to me that the testing framework just handle a null flowfile as an empty set of attributes the way live NiFi does.
---