Loading ccsrc/Protocols/Lost/lost_codec.cc +5 −0 Original line number Diff line number Diff line Loading @@ -109,6 +109,11 @@ int lost_codec::decode (const OCTETSTRING& p_data, LibItsHttp__XmlMessageBodyTyp urn__ietf__params__xml__ns__lost1::ListServicesByLocationResponse list_services_by_location_response; list_services_by_location_response.decode(urn__ietf__params__xml__ns__lost1::ListServicesByLocationResponse_descr_, decoding_buffer, TTCN_EncDec::CT_XER, XER_EXTENDED); msg.listServicesByLocationResponse() = list_services_by_location_response; } else if (it->second.find("<redirect") != std::string::npos) { loggers::get_instance().warning("lost_codec::decode: Process Redirect"); urn__ietf__params__xml__ns__lost1::Redirect redirect; redirect.decode(urn__ietf__params__xml__ns__lost1::Redirect_descr_, decoding_buffer, TTCN_EncDec::CT_XER, XER_EXTENDED); msg.redirect() = redirect; } else if (it->second.find("<findService") != std::string::npos) { urn__ietf__params__xml__ns__lost1::FindService find_service; find_service.decode(urn__ietf__params__xml__ns__lost1::FindService_descr_, decoding_buffer, TTCN_EncDec::CT_XER, XER_EXTENDED); Loading ttcn/AtsECRF/AtsECRF_Pics.ttcn +5 −1 Original line number Diff line number Diff line Loading @@ -2,12 +2,16 @@ module AtsECRF_Pics { type record of charstring request_uri_list; /** * @desc Does the IUT support FindService */ modulepar boolean PICS_ECRF_FIND_SERVICE := true /** * @desc Does the IUT support Redirect? */ modulepar boolean PICS_ECRF_REDIRECT := true /** * @desc Does the IUT support geometry Point? */ Loading ttcn/AtsECRF/AtsECRF_Pixits.ttcn +14 −1 Original line number Diff line number Diff line Loading @@ -31,7 +31,7 @@ module AtsECRF_Pixits { modulepar XSD.String PX_ECRF_SOURCE := "ecrf1.gridgears.plugtests.net"; modulepar XSD.String PX_ECRF_VIA := "ecrf1.gridgears.plugtests.net"; // Should usually be the same as PX_ECRF_SOURCE modulepar StringSet PX_CONFIGURED_SERVICES := { "urn:service:sos", "urn:service:sos.ambulance", "urn:service:sos.fire", "urn:service:sos.police" }; modulepar XSD.Token PX_REDIRECT_TARGET := "other.ecrf.plugtests.net"; // Polygon (Lat/Lon) modulepar DoubleList PX_G1 := { Loading @@ -51,6 +51,16 @@ module AtsECRF_Pixits { 43.548796947590226, 7.048072814941405 }; // Polygon (Lat/Lon) modulepar DoubleList PX_G3 := { 39.232253141714885, 2.252197265625, 39.232253141714885, 4.427490234375, 40.111688665595956, 4.427490234375, 40.111688665595956, 2.252197265625, 39.232253141714885, 2.252197265625 }; // PX_POINT_IN_G1 modulepar DoubleList PX_POINT_IN_G1 := { 43.58206959563555, 6.974515914916991 }; Loading Loading @@ -98,6 +108,9 @@ module AtsECRF_Pixits { 43.60973097491503, 6.9797515869140625 }; // PX_POINT_IN_G3 modulepar DoubleList PX_POINT_IN_G3 := { 39.631076770083666, 2.92236328125 }; // POLICE G1 modulepar XSD.AnyURI PX_URI_POLICE_G1 := "sip:police@g1.esinet.io"; modulepar XSD.String PX_DISPLAY_NAME_POLICE_G1 := "Police G1"; Loading ttcn/AtsECRF/AtsECRF_Templates.ttcn +3 −0 Original line number Diff line number Diff line Loading @@ -26,4 +26,7 @@ module AtsECRF_Templates { in template (present) ListServicesByLocationResponse p_list_services_by_location_response ) := mw_http_response(mw_http_response_ok(mw_http_message_body_xml(mw_body_xml_list_services_by_location_response(p_list_services_by_location_response)))) template HttpMessage mw_http_redirect_response( in template (present) Redirect p_redirect ) := mw_http_response(mw_http_response_ok(mw_http_message_body_xml(mw_body_xml_redirect_response(p_redirect)))) } ttcn/AtsECRF/AtsECRF_TestCases.ttcn +45 −0 Original line number Diff line number Diff line Loading @@ -901,6 +901,51 @@ module AtsECRF_TestCases { f_cf_01_http_down(); } /** * @desc "IUT successfully responds with a service URI for a Point in the service boundary" */ testcase TC_ECRF_LOST_BV_16() runs on HttpComponent system TestAdapter { // Test control f_check_statements({ { name := "PICS_ECRF_FIND_SERVICE", val := PICS_ECRF_FIND_SERVICE }, { name := "PICS_ECRF_GEOMETRY_POINT", val := PICS_ECRF_GEOMETRY_POINT }, { name := "PICS_ECRF_REDIRECT", val := PICS_ECRF_REDIRECT } }) // Test component configuration f_cf_01_http_up(); // Preamble f_sendFindServiceRequest( m_find_service_request( { m_location( PX_LOCATION_ID, { m_extension_point(encvalue_unichar(valueof(m_point(PX_POINT_IN_G1, PX_SRS_NAME, "point1")))) }, "geodetic-2d" // TODO Use a Pixit ) }, { }, PX_E_POLICE_SERVICE_URN, false ) ); f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success); // Test Body tc_ac.start; f_receiveResponse( mw_http_redirect_response( mw_redirect(PX_ECRF_SOURCE,PX_REDIRECT_TARGET,?) ) ); // Postamble f_cf_01_http_down(); } } // End of group LOST } // End of module AtsECRF_TestCases Loading
ccsrc/Protocols/Lost/lost_codec.cc +5 −0 Original line number Diff line number Diff line Loading @@ -109,6 +109,11 @@ int lost_codec::decode (const OCTETSTRING& p_data, LibItsHttp__XmlMessageBodyTyp urn__ietf__params__xml__ns__lost1::ListServicesByLocationResponse list_services_by_location_response; list_services_by_location_response.decode(urn__ietf__params__xml__ns__lost1::ListServicesByLocationResponse_descr_, decoding_buffer, TTCN_EncDec::CT_XER, XER_EXTENDED); msg.listServicesByLocationResponse() = list_services_by_location_response; } else if (it->second.find("<redirect") != std::string::npos) { loggers::get_instance().warning("lost_codec::decode: Process Redirect"); urn__ietf__params__xml__ns__lost1::Redirect redirect; redirect.decode(urn__ietf__params__xml__ns__lost1::Redirect_descr_, decoding_buffer, TTCN_EncDec::CT_XER, XER_EXTENDED); msg.redirect() = redirect; } else if (it->second.find("<findService") != std::string::npos) { urn__ietf__params__xml__ns__lost1::FindService find_service; find_service.decode(urn__ietf__params__xml__ns__lost1::FindService_descr_, decoding_buffer, TTCN_EncDec::CT_XER, XER_EXTENDED); Loading
ttcn/AtsECRF/AtsECRF_Pics.ttcn +5 −1 Original line number Diff line number Diff line Loading @@ -2,12 +2,16 @@ module AtsECRF_Pics { type record of charstring request_uri_list; /** * @desc Does the IUT support FindService */ modulepar boolean PICS_ECRF_FIND_SERVICE := true /** * @desc Does the IUT support Redirect? */ modulepar boolean PICS_ECRF_REDIRECT := true /** * @desc Does the IUT support geometry Point? */ Loading
ttcn/AtsECRF/AtsECRF_Pixits.ttcn +14 −1 Original line number Diff line number Diff line Loading @@ -31,7 +31,7 @@ module AtsECRF_Pixits { modulepar XSD.String PX_ECRF_SOURCE := "ecrf1.gridgears.plugtests.net"; modulepar XSD.String PX_ECRF_VIA := "ecrf1.gridgears.plugtests.net"; // Should usually be the same as PX_ECRF_SOURCE modulepar StringSet PX_CONFIGURED_SERVICES := { "urn:service:sos", "urn:service:sos.ambulance", "urn:service:sos.fire", "urn:service:sos.police" }; modulepar XSD.Token PX_REDIRECT_TARGET := "other.ecrf.plugtests.net"; // Polygon (Lat/Lon) modulepar DoubleList PX_G1 := { Loading @@ -51,6 +51,16 @@ module AtsECRF_Pixits { 43.548796947590226, 7.048072814941405 }; // Polygon (Lat/Lon) modulepar DoubleList PX_G3 := { 39.232253141714885, 2.252197265625, 39.232253141714885, 4.427490234375, 40.111688665595956, 4.427490234375, 40.111688665595956, 2.252197265625, 39.232253141714885, 2.252197265625 }; // PX_POINT_IN_G1 modulepar DoubleList PX_POINT_IN_G1 := { 43.58206959563555, 6.974515914916991 }; Loading Loading @@ -98,6 +108,9 @@ module AtsECRF_Pixits { 43.60973097491503, 6.9797515869140625 }; // PX_POINT_IN_G3 modulepar DoubleList PX_POINT_IN_G3 := { 39.631076770083666, 2.92236328125 }; // POLICE G1 modulepar XSD.AnyURI PX_URI_POLICE_G1 := "sip:police@g1.esinet.io"; modulepar XSD.String PX_DISPLAY_NAME_POLICE_G1 := "Police G1"; Loading
ttcn/AtsECRF/AtsECRF_Templates.ttcn +3 −0 Original line number Diff line number Diff line Loading @@ -26,4 +26,7 @@ module AtsECRF_Templates { in template (present) ListServicesByLocationResponse p_list_services_by_location_response ) := mw_http_response(mw_http_response_ok(mw_http_message_body_xml(mw_body_xml_list_services_by_location_response(p_list_services_by_location_response)))) template HttpMessage mw_http_redirect_response( in template (present) Redirect p_redirect ) := mw_http_response(mw_http_response_ok(mw_http_message_body_xml(mw_body_xml_redirect_response(p_redirect)))) }
ttcn/AtsECRF/AtsECRF_TestCases.ttcn +45 −0 Original line number Diff line number Diff line Loading @@ -901,6 +901,51 @@ module AtsECRF_TestCases { f_cf_01_http_down(); } /** * @desc "IUT successfully responds with a service URI for a Point in the service boundary" */ testcase TC_ECRF_LOST_BV_16() runs on HttpComponent system TestAdapter { // Test control f_check_statements({ { name := "PICS_ECRF_FIND_SERVICE", val := PICS_ECRF_FIND_SERVICE }, { name := "PICS_ECRF_GEOMETRY_POINT", val := PICS_ECRF_GEOMETRY_POINT }, { name := "PICS_ECRF_REDIRECT", val := PICS_ECRF_REDIRECT } }) // Test component configuration f_cf_01_http_up(); // Preamble f_sendFindServiceRequest( m_find_service_request( { m_location( PX_LOCATION_ID, { m_extension_point(encvalue_unichar(valueof(m_point(PX_POINT_IN_G1, PX_SRS_NAME, "point1")))) }, "geodetic-2d" // TODO Use a Pixit ) }, { }, PX_E_POLICE_SERVICE_URN, false ) ); f_selfOrClientSyncAndVerdictPreamble(c_prDone, e_success); // Test Body tc_ac.start; f_receiveResponse( mw_http_redirect_response( mw_redirect(PX_ECRF_SOURCE,PX_REDIRECT_TARGET,?) ) ); // Postamble f_cf_01_http_down(); } } // End of group LOST } // End of module AtsECRF_TestCases