[
https://issues.apache.org/jira/browse/NIFI-11362?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18024482#comment-18024482
]
ASF subversion and git services commented on NIFI-11362:
--------------------------------------------------------
Commit d9eb462f2ccdc52c4a372e85fbb476387e2a9e9d in nifi's branch
refs/heads/main from Haotian Wu
[ https://gitbox.apache.org/repos/asf?p=nifi.git;h=d9eb462f2c ]
NIFI-11362 - Stabilize TestValidateRecord#testValidateJsonTimestamp by
reordering scenarios and resetting reader properties
Signed-off-by: Pierre Villard <[email protected]>
This closes #10359.
> Fixed Flaky Test in TestValidateRecord.java
> -------------------------------------------
>
> Key: NIFI-11362
> URL: https://issues.apache.org/jira/browse/NIFI-11362
> Project: Apache NiFi
> Issue Type: Bug
> Affects Versions: nifi-nar-maven-plugin-1.3.3, 1.10.0,
> nifi-nar-maven-plugin-1.3.2, 1.11.0, 1.12.0, 1.11.1, 1.11.2, 1.11.3, 1.11.4,
> 1.13.0, 1.12.1, 1.14.0, 1.13.1, 1.13.2, 1.15.0, 1.16.0,
> nifi-nar-maven-plugin-1.3.4, 1.15.1, 1.15.2, 1.15.3, 1.17.0, 1.16.1, 1.16.2,
> 1.16.3, nifi-nar-maven-plugin-1.4.0, 1.18.0, 1.19.0, 1.20.0, 1.19.1,
> nifi-nar-maven-plugin-1.5.0
> Environment: Java 11.0.18
> Maven 3.8.1
> Ubuntu 22.034.2 LTS
> Reporter: Armin Rahbar
> Priority: Minor
> Fix For: nifi-nar-maven-plugin-1.5.0
>
> Time Spent: 20m
> Remaining Estimate: 0h
>
> Commit e18d9ce added the flaky test testValidateJsonTimestamp in
> TestValidateRecord.java. The testValidateJsonTimestamp test fails because two
> individual tests inside testValidateJsonTimestamp are order dependent:
> -Test with a timestamp that has an invalid format
> -Test with an Inferred Schema.
> You can produce the failure by running the test with NonDex maven plugin with
> the following command:
> mvn -pl nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors
> edu.illinois:nondex-maven-plugin:2.1.1:nondex
> -Dtest=org.apache.nifi.processors.standard.TestValidateRecord#testValidateJsonTimestamp
> When run with NonDex, testValidateJsonTimestamp test should run successfully,
> but instead, it results in the following failure:
> TestValidateRecord.testValidateJsonTimestamp:549 expected: <1> but was: <0>
> How to fix it:
> Inside testValidateJsonTimestamp, reverse the order of these tests:
> -Test with a timestamp that has an invalid format
> -Test with an Inferred Schema.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)