Uploaded image for project: 'Apache NiFi'
  1. Apache NiFi
  2. NIFI-10692

Possible Array Ordering Permutations Problem in Tests

    XMLWordPrintableJSON

Details

    • Test
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 1.18.0
    • None
    • NiFi Registry
    • None

    Description

      Following the problem of flakiness that occurred in the project

      nifi-nar-bundles/nifi-asn1-bundle/nifi-asn1-services

      test file

      org.apache.nifi.jasn1.TestJASN1RecordReaderWithComplexTypes

      with below three tests

      testBasicTypes
      testRecursive
      testInheritance

      All three above tests use the same file, `JASN1ReadRecordTester` as the tester.
      The test flakiness is due to comparisons between two ArrayList outputs from Class
      `SimpleRecordSchema` which use ArrayList to store one of the parameter `List<RecordField>`

      However, ArrayList does not guarantee entry orders, its object is an unordered set of name/value pairs, and internal permutations may occur in the output as a String.

       

      Steps to reproduce the failure:
      The flakiness was found with NonDex.
      After installing NonDex and run the following code.

      cd nifi
      mvn install -pl nifi-nar-bundles/nifi-asn1-bundle/nifi-asn1-services -am -DskipTests
      mvn -pl nifi-nar-bundles/nifi-asn1-bundle/nifi-asn1-services edu.illinois:nondex- 
        maven-plugin:1.1.3-SNAPSHOT:nondex - 
        Dtest=org.apache.nifi.jasn1.TestJASN1RecordReaderWithComplexTypes#testBasicTypes
      

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              Valvrave Boyu Li
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 40m
                  40m