| /////////////////////////////////////////////////////////////////////////////// |
| // // |
| // Copyright (c) 2000-2019 Ericsson Telecom AB // |
| // // |
| // All rights reserved. This program and the accompanying materials // |
| // are made available under the terms of the Eclipse Public License v2.0 // |
| // which accompanies this distribution, and is available at // |
| // https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.html // |
| /////////////////////////////////////////////////////////////////////////////// |
| |
| /////////////////////////////////////////////////////////// |
| // Module: EPTF_DsRestAPI_Test_Definitions |
| // |
| // Purpose: |
| // This module contains data types for testing EPTF DsRestAPI. |
| // |
| // Module Parameters: |
| // - |
| // Module depends on: |
| // <EPTF_CLL_DsRestAPI_Definitions> |
| // <EPTF_CLL_Base_Definitions> |
| // <EPTF_CLL_DataSource_Definitions> |
| // <EPTF_CLL_Logging_Definitions> |
| // <EPTF_CLL_Common_Definitions> |
| // <EPTF_CLL_DsRestAPI_DSServer_Definitions> |
| // |
| // Current Owner: |
| // Zoltan Zsichla (ezolzsi) |
| // |
| // Last Review Date: |
| // - |
| // |
| // Detailed Comments: |
| // - |
| /////////////////////////////////////////////////////////// |
| module EPTF_DsRestAPI_Test_Definitions { |
| //========================================================================= |
| // Import Part |
| //========================================================================= |
| import from EPTF_CLL_DsRestAPI_Definitions all; |
| import from EPTF_CLL_Base_Definitions all; |
| import from EPTF_CLL_DataSource_Definitions all; |
| import from EPTF_CLL_Logging_Definitions all; |
| import from EPTF_CLL_Common_Definitions all; |
| import from EPTF_CLL_DsRestAPI_DSServer_Definitions all; |
| |
| modulepar charstring tsp_EPTF_DsRestAPI_HTTPServer_RemoteAddress := "127.0.0.1"; |
| modulepar integer tsp_EPTF_DsRestAPI_HTTPServer_RemotePort := 4040; |
| modulepar charstring tsp_EPTF_DsRestAPI_HTTPServer_directory := ""; //"../../../src/WebGUI/"; |
| |
| modulepar charstring tsp_EPTF_DsRestAPI_customizableApp_directory := ""; //"../../../demo/WebGUI/GUICustomization"; |
| modulepar charstring tsp_EPTF_DsRestAPI_API_directory := ""; //"../../../src/DsRestAPI/Api/Js"; |
| |
| //========================================================================= |
| //Component Types |
| //========================================================================= |
| type component DsRestAPI_Test_CT extends EPTF_DsRestAPI_CT, EPTF_Base_CT, EPTF_DataSourceClient_CT { |
| private var integer v_DsRestAPI_Test_loggingMaskId := c_EPTF_Logging_invalidMaskId; |
| |
| // dummy values for creating iterators |
| private var EPTF_CharstringList v_DsRestAPI_Test_entityGroups := {c_DsRestAPI_Test_entityGroup_0, c_DsRestAPI_Test_entityGroup_1}; |
| private var EPTF_CharstringList v_DsRestAPI_Test_scenarios := {c_DsRestAPI_Test_scenario_0, c_DsRestAPI_Test_scenario_1}; |
| private var EPTF_CharstringList v_DsRestAPI_Test_trafficCases := {c_DsRestAPI_Test_trafficCase_0, c_DsRestAPI_Test_trafficCase_1}; |
| private var EPTF_CharstringList v_DsRestAPI_Test_dummy := {c_DsRestAPI_Test_dummy_0, c_DsRestAPI_Test_dummy_1}; |
| |
| private var EPTF_DsRestAPI_Wrapper v_DsRestAPI_Test_DSMock := {}; |
| } |
| |
| const EPTF_DsRestAPI_RqWrapper c_empty_getDataRequest := { requests := {} }; |
| const EPTF_DsRestAPI_ContentAndChildrenListWrapper c_empty_expectedContentList := { contentList := {} }; |
| |
| type record DsRestAPI_Test_Timeline { |
| integer tp, |
| EPTF_IntegerList x, |
| EPTF_CharstringList y |
| } with { |
| variant(tp) "JSON: name as tp"; |
| variant(x) "JSON: name as x"; |
| variant(y) "JSON: name as y"; |
| } |
| |
| type record DsRestAPI_Test_reqResp { |
| charstring requestFileName, |
| charstring responseFileName |
| }; |
| |
| type record of DsRestAPI_Test_reqResp DsRestAPI_Test_reqRespList; |
| |
| group DsRestAPI_Test_DataSource{ |
| |
| type record EPTF_DsRestAPI_TcStart { |
| charstring Value, |
| integer tp |
| } with { |
| variant(Value) "JSON: name as Value"; |
| variant(tp) "JSON: name as tp"; |
| } |
| |
| type record EPTF_DsRestAPI_TcStop { |
| charstring Value, |
| integer tp |
| } with { |
| variant(Value) "JSON: name as Value"; |
| variant(tp) "JSON: name as tp"; |
| } |
| |
| type record EPTF_DsRestAPI_TrafficCase { |
| charstring Value, |
| integer tp, |
| EPTF_DsRestAPI_TcStart TcStart, |
| EPTF_DsRestAPI_TcStop TcStop |
| } with { |
| variant(Value) "JSON: name as Value"; |
| variant(tp) "JSON: name as tp"; |
| variant(TcStart) "JSON: name as TcStart"; |
| variant(TcStop) "JSON: name as TcStop"; |
| } |
| |
| type record of EPTF_DsRestAPI_TrafficCase EPTF_DsRestAPI_TrafficCases; |
| |
| type record EPTF_DsRestAPI_Dummy { |
| charstring Value, |
| integer tp |
| } with { |
| variant(Value) "JSON: name as Value"; |
| variant(tp) "JSON: name as tp"; |
| } |
| |
| type record of EPTF_DsRestAPI_Dummy EPTF_DsRestAPI_DummyList; |
| |
| type record EPTF_DsRestAPI_ScStart { |
| charstring Value, |
| integer tp |
| } with { |
| variant(Value) "JSON: name as Value"; |
| variant(tp) "JSON: name as tp"; |
| } |
| |
| type record EPTF_DsRestAPI_ScStop { |
| charstring Value, |
| integer tp |
| } with { |
| variant(Value) "JSON: name as Value"; |
| variant(tp) "JSON: name as tp"; |
| } |
| |
| type record EPTF_DsRestAPI_ScStatusLED { |
| charstring Value, |
| integer tp |
| } with { |
| variant(Value) "JSON: name as Value"; |
| variant(tp) "JSON: name as tp"; |
| } |
| |
| type record EPTF_DsRestAPI_Scenario { |
| charstring Value, |
| integer tp, |
| EPTF_DsRestAPI_TrafficCases TrafficCases, |
| EPTF_DsRestAPI_DummyList Dummy, |
| EPTF_DsRestAPI_ScStart ScStart, |
| EPTF_DsRestAPI_ScStop ScStop, |
| EPTF_DsRestAPI_ScStatusLED ScStatusLED optional |
| } with { |
| variant(Value) "JSON: name as Value"; |
| variant(tp) "JSON: name as tp"; |
| variant(TrafficCases) "JSON: name as TrafficCases"; |
| variant(Dummy) "JSON: name as Dummy"; |
| variant(ScStart) "JSON: name as ScStart"; |
| variant(ScStop) "JSON: name as ScStop"; |
| variant(ScStatusLED) "JSON: name as ScStatusLED"; |
| } |
| |
| type record of EPTF_DsRestAPI_Scenario EPTF_DsRestAPI_Scenarios; |
| |
| type record EPTF_DsRestAPI_EGrpType { |
| charstring Value, |
| integer tp |
| } with { |
| variant(Value) "JSON: name as Value"; |
| variant(tp) "JSON: name as tp"; |
| } |
| |
| type record EPTF_DsRestAPI_EGrpSize { |
| charstring Value, |
| integer tp |
| } with { |
| variant(Value) "JSON: name as Value"; |
| variant(tp) "JSON: name as tp"; |
| } |
| |
| type record EPTF_DsRestAPI_EntityGroup { |
| charstring Value, |
| integer tp, |
| EPTF_DsRestAPI_Scenarios Scenarios, |
| EPTF_DsRestAPI_EGrpType EGrpType, |
| EPTF_DsRestAPI_EGrpSize EGrpSize |
| } with { |
| variant(Value) "JSON: name as Value"; |
| variant(tp) "JSON: name as tp"; |
| variant(Scenarios) "JSON: name as Scenarios"; |
| variant(EGrpType) "JSON: name as EGrpType"; |
| variant(EGrpSize) "JSON: name as EGrpSize"; |
| } |
| |
| type record of EPTF_DsRestAPI_EntityGroup EPTF_DsRestAPI_EntityGroups; |
| |
| type record EPTF_DsRestAPI_Wrapper { |
| charstring DSClientName, |
| EPTF_DsRestAPI_EntityGroups EntityGroups |
| } with { |
| variant(DSClientName) "JSON: name as DSClientName"; |
| variant(EntityGroups) "JSON: name as EntityGroups"; } |
| |
| const charstring c_DsRestAPI_Test_DataSource_sourceId := "DsRestAPI_Test_DataSource"; |
| const charstring c_DsRestAPI_Test_DS_iteratorVar_prefix := "DsRestAPI_Test_DS_iterator_"; |
| const charstring c_DsRestAPI_Test_DS_var_prefix := "DsRestAPI_Test_DS_var"; |
| |
| // iterators |
| const charstring c_DsRestAPI_Test_iteratorEntityGroups := "EntityGroups"; |
| const charstring c_DsRestAPI_Test_iteratorScenarios := "Scenarios"; |
| const charstring c_DsRestAPI_Test_iteratorTrafficCases := "TrafficCases"; |
| const charstring c_DsRestAPI_Test_iteratorDummy := "Dummy"; |
| |
| const charstring c_DsRestAPI_Test_entityGroup_0 := "EntityGroup_0"; |
| const charstring c_DsRestAPI_Test_entityGroup_1 := "EntityGroup_1"; |
| const charstring c_DsRestAPI_Test_scenario_0 := "Scenario_0"; |
| const charstring c_DsRestAPI_Test_scenario_1 := "Scenario_1"; |
| const charstring c_DsRestAPI_Test_trafficCase_0 := "TrafficCase_0"; |
| const charstring c_DsRestAPI_Test_trafficCase_1 := "TrafficCase_1"; |
| const charstring c_DsRestAPI_Test_dummy_0 := "Dummy_0"; |
| const charstring c_DsRestAPI_Test_dummy_1 := "Dummy_1"; |
| |
| // parameters |
| const charstring c_DsRestAPI_Test_paramNameEntityGroup := "EntityGroup"; |
| const charstring c_DsRestAPI_Test_paramNameScenario := "Scenario"; |
| const charstring c_DsRestAPI_Test_paramNameScenarioInstance := "ScenarioInstance"; |
| const charstring c_DsRestAPI_Test_paramNameTrafficCase := "TrafficCase"; |
| |
| // datalements level 0 |
| const charstring c_DsRestAPI_Test_dataElementEGrpType := "EGrpType"; |
| const charstring c_DsRestAPI_Test_varNameEGrpType := "EntityType"; |
| const charstring c_DsRestAPI_Test_dataElementEGrpSize := "EGrpSize"; |
| const charstring c_DsRestAPI_Test_varNameEGrpSize := "EntityNum" |
| |
| // datalements level 1 |
| const charstring c_DsRestAPI_Test_dataElementScStart := "ScStart"; |
| const charstring c_DsRestAPI_Test_varNameScStart := "startScenario"; |
| const charstring c_DsRestAPI_Test_dataElementScStop := "ScStop"; |
| const charstring c_DsRestAPI_Test_varNameScStop := "stopScenario"; |
| const charstring c_DsRestAPI_Test_dataElementScStatusLED := "ScStatusLED"; |
| const charstring c_DsRestAPI_Test_varNameScStatusLED := "statusLEDScenario"; |
| |
| // datalements level 2 |
| const charstring c_DsRestAPI_Test_dataElementTcStart := "TcStart" |
| const charstring c_DsRestAPI_Test_varNameTcStart := "startTC"; |
| const charstring c_DsRestAPI_Test_dataElementTcStop := "TcStop"; |
| const charstring c_DsRestAPI_Test_varNameTcStop := "stopTC"; |
| |
| // datalements level 2: for getData: |
| const charstring c_DsRestAPI_Test_dataElementTcCPS := "TcCPS"; |
| const charstring c_DsRestAPI_Test_varNameTcCPS := "TcCPS"; |
| } // group DsRestAPI_Test_DataSource |
| |
| } //module |