conformance_test/positive_tests added
[deliverable/titan.core.git] / conformance_test / positive_tests / B_matching_incoming_values / B01_template_matching / B0103_matching_inside_values / B010303_permutation / Sem_B010303_permutation_007.ttcn
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
7 *
8 * Contributors:
9 * Adrien Kirjak – initial implementation
10 *
11 ** @version 0.0.1
12 ** @purpose 1:B.1.3.3, Ensure that all from clause can be used inside permutation
13 ** @verdict pass accept, ttcn3verdict:pass
14 ***************************************************/
15
16 // The following requirement is tested:
17 // Besides specifying all individual values, it is possible to add all elements of
18 // a record of template into permutations using an all from clause.
19
20 module Sem_B010303_permutation_007 {
21
22 type record of integer RoI;
23
24 template RoI t_source := { 1, 2 };
25 template RoI t_perm1 := { permutation (all from t_source), 5 };
26 template RoI t_perm2 := { -1, permutation (0, all from t_source, 3) };
27
28 type component GeneralComp {
29 }
30
31 testcase TC_Sem_B010303_permutation_007() runs on GeneralComp {
32 if (match({ 2, 1, 5 }, t_perm1) and match({ -1, 1, 0, 2, 3 }, t_perm2)) {
33 setverdict(pass);
34 } else {
35 setverdict(fail);
36 }
37 }
38
39 control{
40 execute(TC_Sem_B010303_permutation_007());
41 }
42
43 }
44
This page took 0.031962 seconds and 5 git commands to generate.