{
  "test_id": "ORCL.SCM.MFG.WO.CANCEL",
  "scenario_name": "Cancel Work Order",
  "application": "Oracle Fusion Cloud",
  "product": "SCM",
  "module": "Manufacturing",
  "process": "Cancel Work Order",
  "business_flow": "Plan-to-Produce",
  "scenario_type": "Positive / Negative / Functional",
  "priority": "High",
  "automation_status": "SyntraFlow Ready",
  "library": "Syntra Standard",
  "canonical_url": "https://www.syntraflow.cloud/oracle-erp-testing-tool/test-library/scm/manufacturing/work-orders/cancel-work-order/",
  "objective": {
    "intro": "The objective of this test is to validate cancellation of unreleased, released and partially transacted work orders in Oracle Fusion SCM Manufacturing, without assuming cancellation is universally allowed after transactions begin.",
    "confirms": [
      "an unreleased work order is cancelled successfully",
      "a released work order is cancelled successfully where the manufacturing organization's configuration permits it",
      "a work order with no transactions recorded against it is cancelled cleanly",
      "a partially transacted work order is cancelled only where configuration permits, and correctly blocked otherwise",
      "the work order status correctly transitions to Cancelled when cancellation is eligible, and a cancellation reason is correctly recorded when provided",
      "Oracle correctly enforces validation and security restrictions when data, configuration or authorization issues are introduced (DATA_ERROR, CONFIGURATION_ERROR, SECURITY_ERROR, EXPECTED_VALIDATION)"
    ],
    "scope_note": "This scenario covers cancellation of unreleased, released and partially transacted work orders in Oracle Fusion SCM Manufacturing TEST/UAT environments. Whether a partially transacted work order can be cancelled depends on customer-specific manufacturing organization configuration — this scenario does not assume cancellation is universally allowed once transactions have begun. It does not cover creation, release or update of the work order itself, which are covered by the separate Create, Release and Update Work Order scenarios in the same Work Orders cluster."
  },
  "preconditions": [
    "The work order exists in Oracle Fusion SCM Manufacturing in a status under consideration for cancellation (Unreleased, Released, or partially transacted, subject to configuration).",
    "The work order's transaction history is available for review before cancellation is attempted.",
    "The test user has appropriate access to cancel work orders for the manufacturing organization.",
    "A cancellation reason code is configured where the manufacturing organization requires one.",
    "For partially transacted orders, the manufacturing organization's configuration governing post-transaction cancellation is known."
  ],
  "test_data": [
    {
      "field": "Work Order",
      "example": "${WORK_ORDER}"
    },
    {
      "field": "Work Order Status",
      "example": "${WORK_ORDER_STATUS}"
    },
    {
      "field": "Cancel Reason",
      "example": "${CANCEL_REASON}"
    },
    {
      "field": "Manufacturing Organization",
      "example": "${MANUFACTURING_ORG}"
    },
    {
      "field": "Transaction History",
      "example": "${TRANSACTION_HISTORY}"
    },
    {
      "field": "User Role",
      "example": "${USER_ROLE}"
    }
  ],
  "business_steps": [
    {
      "step_number": 1,
      "step_name": "Sign In and Navigate to Manufacturing",
      "action": "Sign in to Oracle Fusion using an authorised manufacturing test user and navigate to the Manufacturing work area.",
      "test_data": "",
      "expected_result": "The Manufacturing work area opens successfully.",
      "validation_type": "action"
    },
    {
      "step_number": 2,
      "step_name": "Navigate to the Work Order",
      "action": "Open the work order to be cancelled from the work order list.",
      "test_data": "${WORK_ORDER} / ${MANUFACTURING_ORG}",
      "expected_result": "The work order details page opens with the correct status and transaction history.",
      "validation_type": "action"
    },
    {
      "step_number": 3,
      "step_name": "Verify Status and Transaction History",
      "action": "Review the work order's current status and transaction history to confirm cancellation eligibility.",
      "test_data": "${WORK_ORDER_STATUS} / ${TRANSACTION_HISTORY}",
      "expected_result": "Status and transaction history are displayed accurately, including any transactions already recorded against the work order.",
      "validation_type": "action",
      "note": "This single business step replaces multiple technical actions such as opening the transaction history and comparing recorded transactions against cancellation eligibility rules."
    },
    {
      "step_number": 4,
      "step_name": "Select Cancel and Enter Reason",
      "action": "Select the cancel action on the work order and enter a cancellation reason where the manufacturing organization requires one.",
      "test_data": "${CANCEL_REASON}",
      "expected_result": "The cancel action is available for eligible work orders, and the reason field accepts a valid entry where required.",
      "validation_type": "action"
    },
    {
      "step_number": 5,
      "step_name": "Submit the Cancellation",
      "action": "Submit the cancellation request for the work order.",
      "test_data": "${WORK_ORDER_STATUS}",
      "expected_result": "Oracle Fusion processes the cancellation request without unexpected errors, or correctly returns a validation message where cancellation is not permitted.",
      "validation_type": "action"
    },
    {
      "step_number": 6,
      "step_name": "Verify the Work Order Status Updates Correctly",
      "action": "Reopen or refresh the work order and confirm the resulting status.",
      "test_data": "",
      "expected_result": "The work order status correctly shows Cancelled where eligible, or the expected validation message displays where cancellation is not permitted.",
      "validation_type": "business_assertion",
      "note": "This is the primary business assertion for the scenario — a work order correctly transitioning to Cancelled status, or correctly being blocked, is the expected pass condition, not merely a successful save."
    }
  ],
  "expected_results": [
    "The work order correctly transitions to Cancelled status when eligible.",
    "Cancellation of already-cancelled, closed or completed work orders is correctly blocked.",
    "Cancellation of partially transacted work orders correctly follows configured permission rules.",
    "The cancellation reason is correctly recorded when provided.",
    "Status validation is correctly enforced before cancellation.",
    "Unauthorized cancellation is correctly blocked."
  ],
  "validation_checkpoints": [
    "Work order correctly transitions to Cancelled status when eligible.",
    "Cancellation of already-cancelled, closed or completed orders correctly blocked.",
    "Partial-transaction cancellation correctly follows configured permission rules.",
    "Cancel reason correctly recorded.",
    "Status validation correctly enforced before cancellation.",
    "Unauthorized cancellation correctly blocked."
  ]
}
