[
https://issues.apache.org/jira/browse/NIFI-10047?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Chris Sampson reassigned NIFI-10047:
------------------------------------
Assignee: David Handermann (was: Chris Sampson)
> Refactor Groovy Tests to Java
> -----------------------------
>
> Key: NIFI-10047
> URL: https://issues.apache.org/jira/browse/NIFI-10047
> Project: Apache NiFi
> Issue Type: Epic
> Components: Core Framework, Extensions, NiFi Registry
> Reporter: David Handermann
> Assignee: David Handermann
> Priority: Minor
>
> A number of component modules include unit tests written in Groovy, while the
> majority of tests are written in Java. Although Groovy has some advantages
> for testing in particular, the lack of consistency across the framework
> presents several maintenance challenges.
> Groovy is similar enough to Java that it is possible to read with minimal
> effort, but writing idiomatic Groovy requires a greater understanding of the
> language. Some unit tests have leveraged Groovy to bypass method visibility
> constraints, which violates standard class and method contracts. Compiling
> and running tests in Groovy requires additional Maven configuration and
> plugin execution, which contributes to the overall runtime of continuous
> integration workflows. Using Java as the standard language for both
> implementation and tests also makes it easier for contributors to maintain
> and review changes.
> For these reasons, existing Groovy test classes should be rewritten in Java,
> with the exception of scripting components.
> Refactoring and rewriting tests should be done in logical groups of work to
> avoid missing important test functions in the conversion process. Some of the
> modules with larger numbers of Groovy tests include the following:
> * nifi-toolkit-encrypt-config
> * nifi-toolkit-admin
> * nifi-registry-core
> * nifi-security-utils
> * nifi-elasticsearch-restapi-processors
> * nifi-elasticsearch-client-service
> * nifi-framework-cluster
> * nifi-framework-core
> * nifi-web-api
> * nifi-lookup-services
> * nifi-standard-processors
--
This message was sent by Atlassian Jira
(v8.20.10#820010)