-
Notifications
You must be signed in to change notification settings - Fork 11
Description
name: Bug report
about: Create a report to help us improve
title: ''
labels: bug
assignees: ''
Describe the bug
Recently we moved to python latest packages 3.14 and also behave was too updated, and before that all inconclusive tests were Failed and we were able to identify them. but with some of the recent changes, the status is Marked as PASSED whenever there is Inconclusive Step, which also can include a step being missed from the RP run but the overall run Marked as PASSED, which should not be the case!
Steps to Reproduce
Steps to reproduce the behavior:
- Mark the step as inconclusive in the step
- Report portal is mapped with PASSED status for the same
Expected behavior
Tests are inconclusive even when a step is skipped, and this is a clear failure in Scenario
Actual behavior
Due to Fallback logic, Inconclusive result is being marked as PASSED in the Report portal
Package versions
behave 1.2.7
Additional context
The issue is in behave_agent.py:510-528 in the convert_to_rp_status() method:
@staticmethod
def convert_to_rp_status(behave_status: str) -> str:
"""Convert behave test result status to ReportPortal status."""
if behave_status == "passed":
return "PASSED"
elif behave_status == "failed":
return "FAILED"
elif behave_status == "skipped":
return "SKIPPED"
elif behave_status == "error":
return "FAILED"
else:
# todo define what to do
return "PASSED" # CRITICAL BUG: Unknown statuses default to PASSED
The Problem: Any unrecognized status value defaults to "PASSED" (line 528). This means if behave introduces new status types, or if there's any unexpected status value, it will be incorrectly reported as passed in Report Portal.
Recent History
Looking at the recent commits, there was already one fix for this exact issue:
- Commit 7f5b721 (Dec 2025): Added handling for "error" status introduced in behave 1.2.7
- Before this fix, "error" statuses were falling through to the else clause and being marked as PASSED