| /////////////////////////////////////////////////////////////////////////////// |
| // // |
| // 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_PerfTest_Definitions |
| // |
| // Purpose: |
| // This module contains data types for testing EPTF DsRestAPI. |
| // |
| // Module Parameters: |
| // - |
| // Module depends on: |
| // <EPTF_CLL_DsRestAPI_Definitions> |
| // <EPTF_CLL_Base_Definitions> |
| // |
| // Current Owner: |
| // Daniel Gobor (ednigbo) |
| // |
| // Last Review Date: |
| // - |
| // |
| // Detailed Comments: |
| // - |
| /////////////////////////////////////////////////////////// |
| module EPTF_DsRestAPI_PerfTest_Definitions { |
| //========================================================================= |
| // Import Part |
| //========================================================================= |
| import from EPTF_CLL_Base_Definitions all; |
| import from EPTF_CLL_ExecCtrl_Definitions all; |
| import from EPTF_CLL_HostAdmin_Definitions all; |
| import from EPTF_CLL_LGenBase_ConfigDefinitions all; |
| import from EPTF_CLL_LGenBase_Definitions all; |
| import from EPTF_CLL_StatHandlerClient_Definitions all; |
| import from EPTF_CLL_DsRestAPI_DSServer_Definitions all; |
| import from EPTF_CLL_DsRestAPI_Definitions all; |
| import from EPTF_DsRestAPI_Test_Definitions all; |
| import from TestResultGen all; |
| import from ttcn_ericsson_se_TitanSim_Perftest all; |
| |
| |
| //========================================================================= |
| //Component Types |
| //========================================================================= |
| type component DsRestAPI_PerfTest_CT extends EPTF_DsRestAPI_CT, EPTF_Base_CT, EPTF_ExecCtrl_CT, EPTF_HostAdmin_CT, TestResultGen_CT, DsRestAPI_Test_CT { |
| var boolean v_ready := false; |
| var Testresult v_testResult; |
| } |
| |
| const EPTF_DsRestAPI_RqWrapper cg_getDataRequestInt := { |
| requests := { |
| { getData := { |
| source := "ExecCtrl", |
| element := "Start", |
| params := {}, |
| children := {}, |
| selection := {} |
| } |
| } |
| } |
| } |
| |
| const EPTF_DsRestAPI_RqWrapper cg_getDataRequestHelp := { |
| requests := { |
| { getData := { |
| source := "DataSource", |
| element := "help", |
| params := {{ |
| paramName := "Format", |
| paramValue := "TEXT" |
| }}, |
| children := {}, |
| selection := {} |
| } |
| } |
| } |
| } |
| |
| const EPTF_DsRestAPI_RqWrapper cg_getDataRequestSane := { |
| requests := { |
| { |
| getData := { |
| source := "ExecCtrl", |
| element := "EntityGroups", |
| params := {}, |
| |
| children := {{ |
| getData := { |
| source := "ExecCtrl", |
| element := "Scenarios", |
| params := {{ |
| paramName := "EntityGroup", |
| paramValue := "%Parent0%" |
| }}, |
| children := {{ |
| getData := { |
| source := "ExecCtrl", |
| element := "TrafficCases", |
| params := {{ |
| paramName := "EntityGroup", |
| paramValue := "%Parent0%" |
| }, |
| { |
| paramName := "Scenario", |
| paramValue := "%Parent1%" |
| }}, |
| children := {{ |
| getData := { |
| source := "ExecCtrl", |
| element := "TcTargetCPSOrWeight", |
| params := {{ |
| paramName := "EntityGroup", |
| paramValue := "%Parent0%" |
| }, |
| { |
| paramName := "Scenario", |
| paramValue := "%Parent1%" |
| }, |
| { |
| paramName := "TrafficCase", |
| paramValue := "%Parent2%" |
| }} |
| } |
| }}, |
| selection := {0} |
| } |
| }}, |
| selection := {0} |
| } |
| }}, |
| selection := {0} |
| } |
| } |
| } |
| } |
| |
| const charstring cg_EPTF_ExecCtrl_Test_defaultBehaviorName := "ExecCtrTestDefaultBehavior"; |
| const charstring cg_EPTF_ExecCtrl_Test_defaultETypeName := "ExecCtrTestDefaultETypeName"; |
| const charstring cg_EPTF_ExecCtrl_Test_defaultFSMName := "defaultFSM"; |
| const EPTF_LGenBase_FsmTableDeclarator cg_EPTF_ExecCtrl_Test_defaultFSM := |
| { |
| name := cg_EPTF_ExecCtrl_Test_defaultFSMName, |
| fsmParams := { |
| {timerList := {{"busyTimer", 1.0}}}, |
| {stateList := {"idle", "busy"}} |
| ,{varList := { |
| {name := "vf_chrono", initValue := {floatVal := 0.0}, scope := TC} |
| ,{name := "vf_chrono_free", initValue := {floatVal := 0.0}, scope := TC} |
| ,{name := "cf_one", initValue := {intVal := 1}, scope := TC} |
| ,{name := "vf_running", initValue := {intVal := 0}, scope := TC} |
| ,{name := "vf_starts", initValue := {intVal := 0}, scope := TC} |
| }} |
| ,{statMeasStatList := { |
| {name := "mean_rtt", varName := "vf_chrono",statType := mean, scope := TC} |
| ,{name := "mean_busy", varName := "vf_running",statType := max, scope := TC} |
| //,{name := "chrono_free", varName := "",statType := chrono, scope := FSM} |
| }} |
| ,{statMeasWithParamsList := { |
| { |
| name := "maxChrono", |
| providerVarName := "vf_chrono", |
| targetVarName := "", |
| statMeasParams := { |
| statType := max}, |
| scope := TC |
| }, |
| { |
| name := "chrono_busy", |
| providerVarName := "", |
| targetVarName := "vf_chrono", |
| statMeasParams := { |
| statType := chrono}, |
| scope := FSM |
| }, |
| { |
| name := "meanFree", |
| providerVarName := "vf_chrono_free", |
| targetVarName := "", |
| statMeasParams := { |
| statType := mean}, |
| scope := TC |
| }, |
| { |
| name := "chrono_free", |
| providerVarName := "", |
| targetVarName := "vf_chrono_free", |
| statMeasParams := { |
| statType := chrono}, |
| scope := FSM |
| }, |
| { |
| name := "density_free", |
| providerVarName := "vf_chrono_free", |
| targetVarName := "", |
| statMeasParams := { |
| params := { |
| density := { |
| scale := { |
| min := 0.0, |
| max := 19.0, |
| n := 20, |
| scale := linear} |
| } |
| } |
| }, |
| scope := TC |
| }, |
| { |
| name := "p95_free", |
| providerVarName := "vf_chrono_free", |
| targetVarName := "", |
| statMeasParams := { |
| params := { |
| percentile95 := { |
| scale := { |
| min := 0.0, |
| max := 29.0, |
| n := 30, |
| scale := linear} |
| } |
| } |
| }, |
| scope := TC |
| } |
| }} |
| ,{statHandlerStatList := { |
| { |
| name := "MaxBusyTime", |
| providers := { |
| {statMeas := "maxChrono"} |
| }, |
| statMethod := c_EPTF_StatHandler_Method_Max, |
| statResetValue := {floatVal := 0.0}, |
| scope := TC |
| }, |
| { |
| name := "MeanFreeTime", |
| providers := { |
| {statMeas := "meanFree"} |
| }, |
| statMethod := c_EPTF_StatHandler_Method_Mean, |
| statResetValue := {floatVal := 0.0}, |
| scope := TC |
| }, |
| { |
| name := "AvrgFreeTime", |
| providers := { |
| {varList := {"vf_chrono_free", "cf_one"}} |
| }, |
| statMethod := c_EPTF_StatHandler_Method_GlobalAverage, |
| statResetValue := {floatVal := 0.0}, |
| scope := TC |
| }, |
| { |
| name := "Percentile95FreeTime", |
| providers := { |
| {statMeas := "p95_free"} |
| }, |
| statMethod := c_EPTF_StatHandler_Method_Percentile95, |
| statResetValue := {floatVal := 0.0}, |
| scope := TC |
| }, |
| { |
| name := "densityFreeTime", |
| providers := { |
| {statMeas := "density_free"} |
| }, |
| statMethod := c_EPTF_StatHandler_Method_Density, |
| statResetValue := {integerlistVal := {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}}, |
| scope := TC |
| }, |
| { |
| name := "NofBusy", |
| providers := { |
| {varList := {"vf_running"}} |
| }, |
| statMethod := c_EPTF_StatHandler_Method_Sum, |
| statResetValue := {intVal := 0}, |
| scope := TC |
| }, |
| { |
| name := "NofStarts", |
| providers := { |
| {varList := {"vf_starts"}} |
| }, |
| statMethod := c_EPTF_StatHandler_Method_Sum, |
| statResetValue := {intVal := 0}, |
| scope := TC |
| } |
| } |
| } |
| }, |
| table := { classicTable := { |
| {eventToListen := {c_EPTF_LGenBase_behavior,c_EPTF_LGenBase_inputName_testMgmt_startTC,fsm}, |
| cellRow := { |
| //state[0]==idle |
| {{ |
| {c_EPTF_LGenBase_stepName_timerStart,{timerName := "busyTimer"}} |
| ,{stepOrFunctionName := c_EPTF_LGenBase_stepName_fsmResetChrono, contextArgs :={statMeasName := "chrono_busy"}} |
| ,{stepOrFunctionName := c_EPTF_LGenBase_stepName_fsmStartChrono, contextArgs :={statMeasName := "chrono_busy"}} |
| ,{stepOrFunctionName := c_EPTF_LGenBase_stepName_fsmStopChrono, contextArgs :={statMeasName := "chrono_free"}} |
| ,{stepOrFunctionName := c_EPTF_LGenBase_stepName_fsmVarInc, contextArgs :={varParams := {"vf_running",{intVal := 1}}}} |
| ,{stepOrFunctionName := c_EPTF_LGenBase_stepName_fsmVarInc, contextArgs :={varParams := {"vf_starts",{intVal := 1}}}} |
| },omit,"busy"} |
| //state[1]==busy |
| ,{omit,omit,omit} |
| } |
| },{eventToListen := {c_EPTF_LGenBase_specialBName_timerTimeout,"busyTimer",fsm}, |
| cellRow := { |
| //state=idle |
| {omit,omit,omit} |
| //state==busy |
| ,{{ |
| {stepOrFunctionName := c_EPTF_LGenBase_stepName_fsmStopChrono, contextArgs :={statMeasName := "chrono_busy"}} |
| ,{stepOrFunctionName := c_EPTF_LGenBase_stepName_fsmResetChrono, contextArgs :={statMeasName := "chrono_free"}} |
| ,{stepOrFunctionName := c_EPTF_LGenBase_stepName_fsmStartChrono, contextArgs :={statMeasName := "chrono_free"}} |
| ,{stepOrFunctionName := c_EPTF_LGenBase_stepName_fsmVarDec, contextArgs :={varParams := {"vf_running",{intVal := 1}}}} |
| ,{c_EPTF_LGenBase_stepName_trafficSuccess,omit} |
| }, omit,"idle"} |
| } |
| },{eventToListen := {c_EPTF_LGenBase_behavior,c_EPTF_LGenBase_inputName_testMgmt_stopTC,fsm}, |
| cellRow := { |
| //state=idle |
| {omit,omit,omit} |
| //state==busy |
| ,{{ |
| {stepOrFunctionName := c_EPTF_LGenBase_stepName_timerCancelIfRunning, contextArgs :={timerName := "busyTimer"}}, |
| {stepOrFunctionName := c_EPTF_LGenBase_stepName_entityStopped} |
| }, omit,"idle"} |
| } |
| },{eventToListen := {c_EPTF_LGenBase_behavior,c_EPTF_LGenBase_inputName_testMgmt_abortTC,fsm}, |
| cellRow := { |
| //state=idle |
| {omit,omit,omit} |
| //state==busy |
| ,{{ |
| {stepOrFunctionName := c_EPTF_LGenBase_stepName_timerCancelIfRunning, contextArgs :={timerName := "busyTimer"}} |
| }, omit,"idle"} |
| } |
| } |
| }}//table |
| }; |
| |
| } //module |