| /////////////////////////////////////////////////////////////////////////////// |
| // // |
| // Copyright (c) 2000-2017 Ericsson Telecom AB // |
| // // |
| // All rights reserved. This program and the accompanying materials // |
| // are made available under the terms of the Eclipse Public License v1.0 // |
| // which accompanies this distribution, and is available at // |
| // http://www.eclipse.org/legal/epl-v10.html // |
| /////////////////////////////////////////////////////////////////////////////// |
| |
| /////////////////////////////////////////////////////////// |
| // Module: EPTF_Scheduler_Test_Definitions |
| // |
| // Purpose: |
| // This module provides definitions for testing EPTF_CLL_Scheduler |
| // |
| // Module depends on: |
| // - |
| // |
| // Current Owner: |
| // Attila Jenö Balaskó (ETHBAAT) |
| // |
| // Last Review Date: |
| // - |
| // |
| // Detailed Comments: |
| // Provide definitions to the test of EPTF_CLL_Scheduler |
| // |
| // |
| /////////////////////////////////////////////////////////////// |
| module EPTF_Scheduler_Test_Definitions { |
| |
| //import from EPTF_CLL_FBQScheduler_Definitions all; |
| //import from EPTF_CLL_FBQScheduler_Functions all; |
| // to use Red-black tree scheduler, comment the FBQ lines and uncomment these lines: |
| import from EPTF_CLL_RBTScheduler_Definitions all; |
| //import from EPTF_CLL_RBTScheduler_Functions all; |
| import from EPTF_CLL_Scheduler_Definitions all; |
| import from EPTF_CLL_HostAdmin_BaseDefinitions all; |
| import from ttcn_ericsson_se_TitanSim_Perftest all; |
| import from TestResultGen all; |
| |
| modulepar { |
| float tsp_executionTime:=10.0; |
| float tsp_eventGap :=0.1; |
| integer tsp_noOfEvents:=100; |
| integer tsp_deltaNoOfEvents := 10; |
| integer tsp_qNoOfEvents := 3; |
| float tsp_delayBetweenSchAndGen := 0.0; |
| boolean tsp_EPTF_Scheduler_Test_debug := false |
| integer tsp_repeatNo := 10 |
| integer tsp_NrOfTimerReading:= 1000000; |
| } |
| group Demo { |
| |
| type record Event0Data { |
| float period, |
| integer eventIdx, |
| integer maxExecutionNum, |
| integer eventCounter |
| } |
| |
| type Event0Data Event1Data; |
| type record of Event1Data Event1DataList; |
| |
| }//group Demo |
| |
| type record Event2Data { |
| integer eventIdx |
| } |
| type record of Event2Data Event2DataList; // for load test |
| |
| type record LoadStat {float cpuLoad, integer memUsage}; |
| type record of LoadStat LoadStatList; |
| |
| type component EPTF_Scheduler_Test_CT extends EPTF_Scheduler_CT, EPTF_HostAdmin_Base_CT, TestResultGen_CT{ |
| var Event0Data v_event0Data := c_event0Data_empty; |
| var Event1Data v_event1Data := { |
| period := 0.0, |
| eventIdx := -1, |
| maxExecutionNum := 0, |
| eventCounter := 0 |
| } |
| var Event1DataList v_event1DataList:={}; |
| var Event2DataList v_event2DataList:={}; |
| var integer v_eventCounter := 0; //(for evet2Data); |
| var EPTF_Scheduler_ActionHandler v_myEventHandler; |
| var integer v_maxExecutionNum := 0; |
| var float v_firstEventExecTime:=0.0; |
| var float v_lastEventExecTime := 0.0; |
| var integer v_pid:=-1; |
| var LoadStatList v_loadStatList:= {}; |
| var float v_actualHoldingTime:= 0.0; |
| var integer v_actualCPS:=0; |
| var integer v_actualNofSchEvents:=0; |
| var Testresult v_result; |
| } |
| |
| const Event0Data c_event0Data_empty := { |
| period := 0.0, |
| eventIdx := -1, |
| maxExecutionNum := 0, |
| eventCounter := 0 |
| } |
| |
| // how to calculate the timestamp |
| type enumerated WritingMode {incr, decr, rand} |
| type enumerated IncrMode {lin, exp} //lin:10,20,30... exp:10,100,1000 |
| |
| group ParallelTestFuncions { |
| type component EPTF_Scheduler_ParallelTest_CT extends EPTF_Scheduler_CT, EPTF_HostAdmin_Base_CT, TestResultGen_CT { |
| var float v_tLastEvent := -1.0; |
| var float v_dt, v_testcaseDuration; |
| var integer v_nEvents; |
| var boolean v_allEventsProcessed := false; |
| } |
| }//group ParallelTestFuncions |
| |
| }//module |