Commit 4a2179f4 authored by stancakapost's avatar stancakapost
Browse files

No commit message

No commit message
parent 9fc25682
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
/***************************************************
 ** @author   STF 409
 ** @version  $Rev:  $
 ** @purpose  1:6.1.2.2, Assign invalid values to length restricted bitstring.
 ** @purpose  1:6.1.2.4, Assign invalid values to length restricted bitstring.
 ** @verdict  pass reject
 ***************************************************/
module NegSem_06010204_StringLenghtRestrict_001 {
+1 −1
Original line number Diff line number Diff line
/***************************************************
 ** @author   STF 409
 ** @version  $Rev:  $
 ** @purpose  1:6.1.2.2, Assign invalid values to length restricted bitstring.
 ** @purpose  1:6.1.2.4, Assign invalid values to length restricted bitstring.
 ** @verdict  pass reject
 ***************************************************/
module NegSem_06010204_StringLenghtRestrict_002 {
+4 −1
Original line number Diff line number Diff line
/***************************************************
 ** @author   STF 409
 ** @version  $Rev:  $
 ** @purpose  1:6.1.2.2, Assign values to list of types restricted bitstring.
 ** @purpose  1:6.1.2.4, Assign values to list of types restricted bitstring.
 ** @verdict  pass accept, ttcn3verdict:pass
 ***************************************************/
module Sem_06010204_StringLenghtRestrict_001 {
    type bitstring BitStrings1 length(1 .. 2);
    type bitstring BitStrings2 length(5);
    type bitstring BitStrings3 length(0 .. infinity);

    type component GeneralComp {}
    
@@ -16,6 +17,8 @@ module Sem_06010204_StringLenghtRestrict_001 {
        v_b1 := '1'B;
        var BitStrings2 v_b2;
        v_b2 := '10000'B;
        var BitStrings3 v_b3;
        v_b3 := '111111'B;
		setverdict(pass);
    }
    
+20 −0
Original line number Diff line number Diff line
/***************************************************
 ** @author   STF 409
 ** @version  $Rev:  $
 ** @purpose  1:6.1.2.5, Assign invalid values to pattern restricted character strings.
 ** @verdict  pass reject
 ***************************************************/
module NegSem_06010205_StringPattern_001 {
    type charstring MyString (pattern "?bc*xyz");
    
    type component GeneralComp {}
    
    testcase TC_NegSem_06010205_StringPattern_001() runs on GeneralComp {
        var MyString v_c := "abcyz"; // value missing x
		setverdict(pass);
    }
    
    control{
        execute(TC_NegSem_06010205_StringPattern_001());
    }
}
 No newline at end of file
+25 −0
Original line number Diff line number Diff line
/***************************************************
 ** @author   STF 409
 ** @version  $Rev:  $
 ** @purpose  1:6.1.2.5, Assign values to pattern restricted character strings.
 ** @verdict  pass accept, ttcn3verdict:pass
 ***************************************************/
module Sem_06010205_StringPattern_001 {
    type charstring MyString (pattern "abc*xyz");

    type component GeneralComp {}
    
    testcase TC_Sem_06010205_StringPattern_001() runs on GeneralComp {
        var MyString v_c;
        v_c := "abcxyz";
        v_c := "abc123xyz";
        v_c := "abc:xyz";
        v_c := "abc...xyz";
        v_c := "abc*xyz";
		setverdict(pass);
    }
    
    control{
        execute(TC_Sem_06010205_StringPattern_001());
    }
}
 No newline at end of file
Loading