Skip to content

[tests-only][full-ci] fix: correct regex on test script#11647

Merged
nabim777 merged 1 commit intomasterfrom
tests/fix-regex-on-script
Sep 12, 2025
Merged

[tests-only][full-ci] fix: correct regex on test script#11647
nabim777 merged 1 commit intomasterfrom
tests/fix-regex-on-script

Conversation

@nabim777
Copy link
Member

@nabim777 nabim777 commented Sep 12, 2025

Description

Due to changes In Behat v3.24.0, the output format changed and now includes the extra (on line X) text in failed scenario reporting.

New format in v3.24.0:

coreApiAuth/webDavMKCOLAuth.feature:42 (on line 50)

Previous versions v3.13:

coreApiAuth/webDavMKCOLAuth.feature:42

This is why in script file FAILED_SCENARIO_PATHS variable was getting the extra text (on line 50).

So, this PR added regex that removes everything after .feature:X, including the new (on line X) text.

Related Issue

  • Fixes <issue_link>

Motivation and Context

When tests fail, the output was showing broken text like:

coreApiAuth/webDavMKCOLAuth.feature:42
./(on
./line
./50)

How Has This Been Tested?

  • test environment:
  • test case 1:
  • test case 2:
  • ...

Screenshots (if appropriate):

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Technical debt
  • Tests only (no source changes)

Checklist:

  • Code changes
  • Unit tests added
  • Acceptance tests added
  • Documentation ticket raised:

Signed-off-by: nabim777 <nabinalemagar019@gmail.com>
@nabim777 nabim777 force-pushed the tests/fix-regex-on-script branch from 4f104dd to 4cc4d57 Compare September 12, 2025 09:26
@sonarqubecloud
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants