Commit 37acaed1 authored by YannGarcia's avatar YannGarcia

Validate first BwManagementAPI test

parent 3fc07e0e
......@@ -79,9 +79,24 @@ int json_codec::decode (const OCTETSTRING& p_data, LibItsHttp__JsonMessageBodyTy
msg.ueIdentityTagInfo() = ue_identity_tag_info;
} else if (it->second.find("\"bwInfo\"") != std::string::npos) {
BwManagementAPI__TypesAndValues::BwInfo bw_info;
bw_info.decode(BwManagementAPI__TypesAndValues::BwInfo_descr_, decoding_buffer, TTCN_EncDec::CT_JSON);
// Need to change some enumerated string not supported by TTCN-3 language
if (str.find("not defined in the present document") != std::string::npos) {
str = regex_replace(str, regex("not defined in the present document"), "not_defined_in_the_present_document");
}
if (str.find("00 = Downlink (towards the UE)") != std::string::npos) {
str = regex_replace(str, regex("00 = Downlink \\(towards the UE\\)"), "Downlink");
} else if (str.find("01 = Uplink (towards the application/session)") != std::string::npos) {
str = regex_replace(str, regex("01 = Uplink \\(towards the application\\/session\\)"), "Uplink");
} else if (str.find("10 = Symmetrical") != std::string::npos) {
str = regex_replace(str, regex("10 = Symmetrical"), "Symmetrical");
}
//loggers::get_instance().log("json_codec::decode: ##########; %s", str.c_str());
TTCN_Buffer decoding_buffer_(OCTETSTRING(str.length(), (const unsigned char*)str.c_str()));
bw_info.decode(BwManagementAPI__TypesAndValues::BwInfo_descr_, decoding_buffer_, TTCN_EncDec::CT_JSON);
msg.bwInfo() = bw_info;
} else if (it->second.find("\"problemDetails\"") != std::string::npos) {
} else if (it->second.find("\"problemDetails\"") != std::string::npos) { // TODO To be refined, problemDetails in different modules
UEidentityAPI__TypesAndValues::ProblemDetails problem_details;
problem_details.decode(UEidentityAPI__TypesAndValues::ProblemDetails_descr_, decoding_buffer, TTCN_EncDec::CT_JSON);
msg.problemDetails__ue__identity() = problem_details;
......
......@@ -8,12 +8,20 @@ LibCommon_Sync.PX_TSYNC_TIME_LIMIT := 30.0;
LibCommon_Sync.PX_TSHUT_DOWN_TIME_LIMIT := 30.0;
#LibItsHttp_Pics.PICS_HEADER_HOST := "172.28.4.87"
LibItsHttp_Pics.PICS_HEADER_HOST := "192.168.1.21"
LibItsHttp_Pics.PICS_HEADER_HOST := "192.168.0.5"
LibItsHttp_Pics.PICS_HEADER_CONTENT_TYPE := "application/json"
LibMec_Pics.PICS_MEC_PLAT := true
LibMec_Pics.PICS_RNIS := true
LibMec_Pics.PICS_RNIS := true
LocationAPI_Pics.PICS_LOCATION_API_SUPPORTED := true
LocationAPI_Pics.PICS_LOCATION_API_SUPPORTED := true
LocationAPI_Pics.PICS_LOCATION_API_SUPPORTED := true
UEidentityAPI_Pics.PICS_UE_IDENTITY_API_SUPPORTED := true
BwManagementAPI_Pics.PICS_BWMANAGEMENT_API_SUPPORTED := true
[LOGGING]
# In this section you can specify the name of the log file and the classes of events
......@@ -31,7 +39,7 @@ LogEventTypes:= Yes
[TESTPORT_PARAMETERS]
# In this section you can specify parameters that are passed to Test Ports.
system.httpPort.params := "HTTP(codecs=json:json_codec)/TCP(debug=1,server=192.168.1.21,port=8081,use_ssl=0)"
system.httpPort.params := "HTTP(codecs=json:json_codec)/TCP(debug=1,server=192.168.0.5,port=8081,use_ssl=0)"
[DEFINE]
# In this section you can create macro definitions,
......
......@@ -39,8 +39,10 @@ module AtsMec_TestControl {
}
}
if (PICS_RNIS_ALL_SUBSCRIPTIONS) {
execute(TC_MEC025_RNIS_SUBSCRIPTION_005());
if (PICS_RNIS) {
if (PICS_RNIS_ALL_SUBSCRIPTIONS) {
execute(TC_MEC025_RNIS_SUBSCRIPTION_005());
}
}
if (PICS_BWMANAGEMENT_API_SUPPORTED) {
......
......@@ -90,7 +90,7 @@ module BwManagementAPI_TypesAndValues {
* @desc Indicates the allocation priority when dealing with several applications or sessions in parallel. Values are not defined in the present document
*/
type enumerated FixedBWPriority {
reserved
not_defined_in_the_present_document
}
/**
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment