OneM2M_TestSystem.ttcn 3.01 KB
Newer Older
1 2 3 4 5 6 7 8
/**
 *  Copyright Notification
 *  No part of this document may be reproduced, in an electronic retrieval system or otherwise, except as authorized by written permission.
 *  The copyright and the foregoing restriction extend to reproduction in all media.
 *  © 2016, oneM2M Partners Type 1 (ARIB, ATIS, CCSA, ETSI, TIA, TSDSI, TTA, TTC).
 *  All rights reserved.
 *  
 *  @author     ETSI
9 10
 *  @version    $URL: https://oldforge.etsi.org/svn/oneM2M/branches/Release1/ttcn/LibOneM2M/OneM2M_TestSystem.ttcn $
 *              $Id: OneM2M_TestSystem.ttcn 347 2017-08-11 08:48:20Z reinaortega $
11 12 13 14 15 16
 *  @desc       Test System module for oneM2M
 *
 */
module OneM2M_TestSystem {

	import from OneM2M_Types all;
17 18 19
	import from LibCommon_Time all;
	import from OneM2M_Ports all;
	import from OneM2M_Pixits all;
20

21 22 23 24
/* ***************************************
 * 		Test System Components 
 * ***************************************
 */	
25
	type component Tester {
26
		port AdapterControlPort acPort;
27
		port InfoPort infoPort;
28
		port UpperTesterPort utPort;
29 30
		//timers
		timer tc_ac := PX_TAC;
31
		timer tc_wait := PX_TWAIT;
32
		//global variables
33
		var charstring vc_protocolBinding;
34
		var Configurations vc_config;
35
		var TestSystemRole vc_testSystemRole;
36
		var MyResourcesList vc_resourcesList;
37
		var IntegerList vc_resourcesIndexToBeDeleted := {};
38
		var integer vc_aeAuxIndex := -1;//TODO To be removed
39
		var integer vc_remoteCseIndex := -1;
40
		var integer vc_acpAuxIndex := -1;
41
		var AccessControlPolicy_optional vc_acpAux;
42 43
		var MsgIn vc_request;
		var MsgIn vc_response;
44 45
		var default vc_aeSimu := null;
		var default vc_cseSimu := null;
46
	};
47 48
	
	type component AeSimu extends Tester {
49
		var AeSimu vc_ae2;
50 51 52 53 54 55
		port OneM2MPort mcaPort;
		port OneM2MPort mcaPortIn;
	
		//global variables
		var PrimitiveContent vc_primitiveContentRetrievedResource;

56
		var CseSimu vc_cse1;//For CF02 when AeSimu is master
57 58
		var boolean vc_auxiliaryAe2Up := false;
	};
59
		
60
	type component CseSimu extends Tester {
61
		port OneM2MPort mcaPort;
62
		port OneM2MPort mcaPortIn;
63
		port OneM2MPort mccPort;
64
		port OneM2MPort mccPortIn;
65

66
		//global variables
67
		var MyResourcesList vc_localResourcesList := {};
68
		var AeSimu vc_ae1;//For CF02 when CseSimu is master
69 70
		var integer vc_localRemoteCseIndex := -1;
		var integer vc_cSEBaseIndex := -1;	//Index of the CSEBase resource of the Tester inside vc_localResourcesList
Miguel Angel Reina Ortega's avatar
Miguel Angel Reina Ortega committed
71
		var CseTypeID vc_cseType;	//cseType of the simulated CSE. IN =1, MN = 2
72
	};
73
	
74 75
	type component InCseSimu extends CseSimu {
	}
76
	
77 78
	type component MnCseSimu extends CseSimu {
	}
79
			
80
	type component CseSystem {
81
		port OneM2MPort mcaPort;
82
		port OneM2MPort mcaPortIn;
83
		port OneM2MPort mccPort;
84
		port OneM2MPort mccPortIn;
85
		port AdapterControlPort acPort;
86
		port UpperTesterPort utPort;
87 88 89 90
	}	
	
	type component AeSystem {
		port OneM2MPort mcaPort;
91
		port OneM2MPort mcaPortIn;
92
		port AdapterControlPort acPort;
93
		port UpperTesterPort utPort;
94 95 96
	}		
	
			
97
	
98
	
99 100

}// end of module
101 102 103 104
with {
	extension "anytype charstring"

}