*** Settings ***
Documentation    Integration tests for actor add rich output panels
Resource         ${CURDIR}/common.resource
Suite Setup      Setup Test Environment
Suite Teardown   Cleanup Test Environment

*** Variables ***
${HELPER}    ${CURDIR}/helper_actor_add_rich_output.py

*** Test Cases ***
Actor Add Rich Output Contains Type Field
    [Documentation]    Verify that ``actor add`` rich output includes the Type field
    [Tags]    tdd_issue    tdd_issue_4200    tdd_expected_fail
    ${result}=    Run Process    ${PYTHON}    ${HELPER}    add-type-field    cwd=${WORKSPACE}
    Log    ${result.stdout}
    Log    ${result.stderr}
    Should Be Equal As Integers    ${result.rc}    0
    Should Contain    ${result.stdout}    actor-add-type-field-ok

Actor Add Rich Output Contains Config Panel
    [Documentation]    Verify that ``actor add`` rich output includes the Config panel
    [Tags]    tdd_issue    tdd_issue_4200    tdd_expected_fail
    ${result}=    Run Process    ${PYTHON}    ${HELPER}    add-config-panel    cwd=${WORKSPACE}
    Log    ${result.stdout}
    Log    ${result.stderr}
    Should Be Equal As Integers    ${result.rc}    0
    Should Contain    ${result.stdout}    actor-add-config-panel-ok

Actor Add Rich Output Contains Capabilities Panel
    [Documentation]    Verify that ``actor add`` rich output includes the Capabilities panel
    [Tags]    tdd_issue    tdd_issue_4200    tdd_expected_fail
    ${result}=    Run Process    ${PYTHON}    ${HELPER}    add-capabilities-panel    cwd=${WORKSPACE}
    Log    ${result.stdout}
    Log    ${result.stderr}
    Should Be Equal As Integers    ${result.rc}    0
    Should Contain    ${result.stdout}    actor-add-capabilities-panel-ok

Actor Add Rich Output Contains Tools Panel
    [Documentation]    Verify that ``actor add`` rich output includes the Tools panel
    [Tags]    tdd_issue    tdd_issue_4200    tdd_expected_fail
    ${result}=    Run Process    ${PYTHON}    ${HELPER}    add-tools-panel    cwd=${WORKSPACE}
    Log    ${result.stdout}
    Log    ${result.stderr}
    Should Be Equal As Integers    ${result.rc}    0
    Should Contain    ${result.stdout}    actor-add-tools-panel-ok

Actor Add Rich Output Contains Success Line
    [Documentation]    Verify that ``actor add`` rich output ends with the success status line
    [Tags]    tdd_issue    tdd_issue_4200    tdd_expected_fail
    ${result}=    Run Process    ${PYTHON}    ${HELPER}    add-success-line    cwd=${WORKSPACE}
    Log    ${result.stdout}
    Log    ${result.stderr}
    Should Be Equal As Integers    ${result.rc}    0
    Should Contain    ${result.stdout}    actor-add-success-line-ok
