Remove trailing spaces in robot scripts
[testsuite.git] / robot / resources / test_templates / model_test_template_vcperescust.robot
1 *** Settings ***
2 Documentation     Distribute models for vcpe
3 Library           OperatingSystem
4 Library            ArchiveLibrary
5 Library           Collections
6 Library           String
7 Library           DateTime
8 Library           ONAPLibrary.ServiceMapping    WITH NAME    ServiceMapping
9 Resource          ../sdc_interface.robot
10
11 *** Variables ***
12 ${SDC_ASSETS_DIRECTORY}    ${GLOBAL_HEAT_TEMPLATES_FOLDER}
13 ${SDC_ZIP_DIRECTORY}    ${SDC_ASSETS_DIRECTORY}/temp
14
15 *** Keywords ***
16 Model Distribution For vCPEResCust Directory
17     [Arguments]    ${service}   ${catalog_service_name}=    ${cds}=
18     ServiceMapping.Set Directory    default    ${GLOBAL_SERVICE_MAPPING_DIRECTORY}
19     ${directory_list}=    ServiceMapping.Get Service Folder Mapping    default    ${service}
20     ${ziplist}=    Create List
21     ${uuid}=    Get Current Date
22     ${service_name}=    Catenate    ${service}    ${uuid}
23     ${shortened_uuid}=     Evaluate    str("${service_name}")[:23]
24     ${catalog_service_name}=   Set Variable If   '${catalog_service_name}' ==''   ${shortened_uuid}   ${catalog_service_name}
25     :FOR   ${directory}    IN    @{directory_list}
26     \    ${zipname}=   Replace String    ${directory}    /    _
27     \    ${zip}=    Catenate    ${SDC_ZIP_DIRECTORY}/${zipname}.zip
28     \    ${folder}=    Catenate    ${SDC_ASSETS_DIRECTORY}/${directory}
29     \    OperatingSystem.Create Directory    ${SDC_ASSETS_DIRECTORY}/temp
30     \    Create Zip From Files In Directory        ${folder}    ${zip}
31     \    Append To List    ${ziplist}    ${zip}
32     ${catalog_service_name}    ${catalog_resource_name}    ${vf_modules}    ${catalog_resource_ids}   ${catalog_service_id}   ${catalog_resources}   Distribute vCPEResCust Model From SDC    ${ziplist}    ${catalog_service_name}    ${cds}   ${service}
33     Download CSAR    ${catalog_service_id}
34     [Return]    ${catalog_service_name}    ${catalog_resource_name}    ${vf_modules}   ${catalog_resources}