Skip to content

[BUG] Completed and canceled progress states are not treated as terminal #1194

Description

@NaitikVerma6776

Description

progress_type_request does not correctly reject progress updates after a test has reached completed or canceled.

TestStatus.progress_step() returns an integer progress index, but the returned integer was compared directly against TestStatus.completed and TestStatus.canceled enum symbols.

As a result, terminal states could be incorrectly treated as active progress states.

Expected behavior

If the latest progress status is completed or canceled, a subsequent progress update should be rejected and the progress trail should remain unchanged.

Actual behavior

The terminal-state guard was bypassed, allowing additional progress entries after completed or canceled.

Reproduction

Regression tests demonstrate that:

  • completed -> completed was accepted
  • canceled -> completed was accepted

Fix

Compare the stored TestStatus enum directly against the terminal enum values, while retaining progress_step() for numeric progress ordering.

Tests

Regression tests cover both completed and canceled terminal states.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions