/*****************************************************************
 ** @author   STF 433
 ** @version  0.0.1
 ** @purpose  1:15.3, Ensure that a send operation with actual parameters of a global parameterized template is accepted with the actual parameter being an inline template.
 ** @verdict  pass accept, ttcn3verdict:pass
 *****************************************************************/

module Sem_1503_GlobalAndLocalTemplates_006 {

    type port MyMessagePortType message {
        inout MyMessageType
    }

    type component GeneralComp {
        port MyMessagePortType pt_myPort;
    }

    type record MyMessageType {
        integer field1,
        charstring field2,
        MyMessageType field3 optional
    }

    template MyMessageType m_myOtherTemplate(template MyMessageType p_myTemplate):= {
        field1 := 2,
        field2 := "abcxyz",
        field3 := p_myTemplate
    }

    testcase TC_Sem_1503_GlobalAndLocalTemplates_006() runs on GeneralComp {
        pt_myPort.send(m_myOtherTemplate(MyMessageType:{2,"foobar",omit}));
        setverdict(pass);
    }

    control{
        execute(TC_Sem_1503_GlobalAndLocalTemplates_006());
    }


}