conformance_test/positive_tests added
[deliverable/titan.core.git] / conformance_test / positive_tests / 06_types_and_values / 0603_type_compatibility / 060302_structured_types / NegSem_060302_structured_types_012.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:6.3.2, Ensure that the IUT rejects assignments having mismatch between undefined and omitted elements
13 ** @verdict pass reject
14 ***************************************************/
15
16 module NegSem_060302_structured_types_012 {
17
18 type record RecordType {
19 integer a,
20 integer b optional
21 }
22
23 type set SetType {
24 integer a,
25 integer b optional
26 }
27
28 type record length (1..2) of integer ShortIntegerList;
29 type record of integer IntegerList;
30
31 type set length (1..2) of integer ShortUnorderedIntegerList;
32 type set of integer UnorderedIntegerList;
33
34
35 type component GeneralComp {
36 }
37
38 testcase TC_NegSem_060302_structured_types_012() runs on GeneralComp {
39
40
41 var IntegerList v_list1:={1,-};
42 var ShortIntegerList v_list2;
43 var RecordType v_rec1;
44 var UnorderedIntegerList v_ulist1:={1,-};
45 var ShortUnorderedIntegerList v_ulist2;
46 var SetType v_set1;
47
48 var integer v_matcher[2] := {1,-};
49
50 var boolean v_check1;
51
52 v_list2:=v_list1;
53 v_rec1:=v_list2;
54 v_ulist2:=v_ulist1;
55 v_set1:=v_ulist2;
56
57 v_check1 := match(v_rec1, v_matcher); //mismatch between undefined and omitted elements
58
59 }
60
61 control{
62 execute(TC_NegSem_060302_structured_types_012());
63 }
64
65 }
This page took 0.032842 seconds and 5 git commands to generate.