Commit 09ad846c authored by Houcem Kacem's avatar Houcem Kacem
Browse files

fix: fix batch entities tcs

parent f1670694
Loading
Loading
Loading
Loading
+5 −3
Original line number Diff line number Diff line
@@ -29,12 +29,14 @@ Batch Create Entity Scenarios

    Batch Create Entities   @{entities_to_be_created}

    ${expected_entities_ids}=  Catenate    SEPARATOR=,     ${first_entity_id}     ${second_entity_id}
    @{expected_entities_ids}=  Create List   ${first_entity_id}     ${second_entity_id}
    ${entities_to_be_queried}=  Catenate    SEPARATOR=,     ${first_entity_id}     ${second_entity_id}

    Check Response Status Code Set To  201
    Check Response Body Containing Array Of URIs set to   @{expected_entities_ids}

    Query Entities    ${expected_entities_ids}  Building    context=${ngsild_test_suite_context}
    Check Created Resources Set To     ${entities_to_be_created}
    Query Entities    ${entities_to_be_queried}  Building    context=${ngsild_test_suite_context}
    ${ignored_keys}=    Create List     ${context_regex_expr}
    Check Created Resources Set To     ${entities_to_be_created}    ${ignored_keys}

    Batch Delete Entities       @{expected_entities_ids}
+2 −2
Original line number Diff line number Diff line
@@ -34,8 +34,8 @@ Create a batch of two valid entities and one invalid entity

    Query Entities    ${expected_entities_ids}  Building    context=${ngsild_test_suite_context}
    @{created_entities}=  Create List   ${first_entity}     ${second_entity}
    Check Created Resources Set To     ${created_entities}

    ${ignored_keys}=    Create List     ${context_regex_expr}
    Check Created Resources Set To     ${created_entities}      ${ignored_keys}
    @{entities_ids_to_be_deleted}=  Create List   ${first_entity_id}     ${second_entity_id}    ${existing_entity_id}
    Batch Delete Entities       @{entities_ids_to_be_deleted}

+2 −1
Original line number Diff line number Diff line
@@ -40,7 +40,8 @@ Batch Update Entity Scenarios
    @{updated_entities}=  Create List   ${first_updated_entity}     ${second_updated_entity}
    ${expected_entities_ids}=  Catenate    SEPARATOR=,     @{entities_ids_to_be_updated}
    Query Entities    ${expected_entities_ids}  Building    context=${ngsild_test_suite_context}
    Check Updated Resources Set To   ${updated_entities}
    ${ignored_keys}=    Create List     ${context_regex_expr}
    Check Updated Resources Set To   ${updated_entities}    ${ignored_keys}

Setup Initial Entities
    ${first_entity_id}=     Generate Random Entity Id    ${building_id_prefix}
+2 −1
Original line number Diff line number Diff line
@@ -40,7 +40,8 @@ Batch Update Entity With NoOverwrite Option Scenarios
    @{updated_entities}=  Create List   ${first_updated_entity}     ${second_updated_entity}
    ${expected_entities_ids}=  Catenate    SEPARATOR=,     @{entities_ids_to_be_updated}
    Query Entities    ${expected_entities_ids}  Building    context=${ngsild_test_suite_context}
    Check Updated Resources Set To   ${updated_entities}
    ${ignored_keys}=    Create List     ${context_regex_expr}
    Check Updated Resources Set To   ${updated_entities}    ${ignored_keys}

Setup Initial Entities
    ${first_entity_id}=     Generate Random Entity Id    ${building_id_prefix}
+2 −1
Original line number Diff line number Diff line
@@ -40,7 +40,8 @@ Update a batch of non existing and existing entities
    @{updated_entities}=  Create List   ${first_updated_entity}     ${second_updated_entity}
    ${expected_entities_ids}=  Catenate    SEPARATOR=,     @{expected_successful_entities_ids}
    Query Entities    ${expected_entities_ids}  Building    context=${ngsild_test_suite_context}
    Check Updated Resources Set To   ${updated_entities}
    ${ignored_keys}=    Create List     ${context_regex_expr}
    Check Updated Resources Set To   ${updated_entities}    ${ignored_keys}

    Batch Delete Entities       @{expected_successful_entities_ids}

Loading