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:22.2.3, redirect assignment of message fields
13 ** @verdict pass accept, ttcn3verdict:pass
14 *****************************************************************/
16 // The following requirements are tested:
17 // Rules in clause 22.2.2 shall apply.
18 // When the keyword value is followed by an assignment list enframed by a pair of
19 // parentheses, the whole received message and/or one or more parts of it can be
20 // stored. In a single assignment within the list, on the right hand side of the
21 // assignment symbol (":=") a field of the template type shall be referenced, on
22 // the left hand side the name of the variable or a formal parameter, in which
23 // the value shall be stored.
25 module Sem_220203_TriggerOperation_009 {
34 } with {extension "internal"}
36 type component GeneralComp
41 testcase TC_Sem_220203_TriggerOperation_009() runs on GeneralComp {
45 connect(self:p, self:p);
46 p.send(R:{ field1 := { 1, 2 }, field2 := "abc" });
48 [] p.trigger(R:?) -> value ( v_int := field1[1], v_str := field2) {
49 if (v_int == 2 and v_str == "abc") { setverdict (pass); }
50 else { setverdict(fail); }
56 execute(TC_Sem_220203_TriggerOperation_009(), 5.0);