1 /******************************************************************************
2 * Copyright (c) 2000-2016 Ericsson Telecom AB
3 * All rights reserved. This program and the accompanying materials
4 * are made available under the terms of the Eclipse Public License v1.0
5 * which accompanies this distribution, and is available at
6 * http://www.eclipse.org/legal/epl-v10.html
9 * Adrien Kirjak – initial implementation
12 ** @purpose 1:B.1.2.5, Ensure that the IUT correctly handles template matching of value range definitions
13 ** @verdict pass accept, ttcn3verdict:pass
14 ***************************************************/
16 module Sem_B010205_value_range_007 {
18 type enumerated EnumeratedType {e_black, e_white, e_green};
20 type record RecordType {
26 type union UnionType {
32 type record MessageType {
39 type port loopbackPort message {
41 } with {extension "internal"}
44 type component GeneralComp {
45 port loopbackPort messagePort
48 testcase TC_Sem_B010205_value_range_007() runs on GeneralComp {
50 var MessageType v_testMessage;
52 template MessageType mw_matchingTemplate:=
54 field1 := (0..!2), //value is out of range because of exclusive upper boundary
55 field2 := ("a".."f") length (3),
56 field3 := {a:=1,b:=(0..2),c:=true},
63 field3 := {a:=1,b:=2,c:=true},
67 connect(self:messagePort, self:messagePort);
68 messagePort.send(v_testMessage);
71 [] messagePort.receive(mw_matchingTemplate) {
74 [] messagePort.receive {
81 execute(TC_Sem_B010205_value_range_007());