Uploaded image for project: 'Migration Toolkit for Applications'
  1. Migration Toolkit for Applications
  2. MTA-6234

User friendly jenkins report for KAI runs

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Done
    • Icon: Undefined Undefined
    • None
    • None
    • Migration QE Infra
    • Quality / Stability / Reliability
    • 5
    • False
    • Hide

      None

      Show
      None
    • False
    • None

      Hi rhn-support-mmansoor rh-ee-abrugaro

       

      Can you please give it a try : 

       

       

      We can make the jenkins output for KAI tests more readable and user friendly by using junit .

      I did some research and found this useful .

      Jenkins has native support for parsing JUnit XML test results, showing pass/fail counts in green/red, with clickable logs.

      Modifications required in bat file : 

      npx playwright test --project analysis-tests --no-deps --reporter=list,junit --output=playwright-report --reporter-junit-output=results.xml >> %LOG% 2>&1 

       

      That will:

      • still print progress to the console
      • generate results.xml (JUnit format)
      • put test artifacts in playwright-report/    
      • In Jenkinsfile, add a post-build step:
        post {
          always {
            junit allowEmptyResults: true, testResults: '**/results.xml'
            archiveArtifacts artifacts: 'playwright-report/**', allowEmptyArchive: true
          }
        }

        Now Jenkins will automatically:

        • show a test summary table (✅ Passed / ❌ Failed)
        • color-code the results in the UI
        • link to logs and stack traces per test

      To get colored output directly in Jenkins logs.

       

      options {
        ansiColor('xterm')
      }

              rhn-support-mmansoor M Sajid Mansoori
              rhn-support-sshveta Shveta Sachdeva
              Shveta Sachdeva Shveta Sachdeva
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: