Update vendor extension in pipeline

This commit is contained in:
Vivek Kumar Dutta 2025-02-25 17:14:04 +05:30
parent 6e80cefd00
commit 8bb5c68295
No known key found for this signature in database
GPG key ID: 4E09F5AD8265FD4C
12 changed files with 36 additions and 36 deletions

View file

@ -1,5 +1,5 @@
variables: variables:
CFLAGS: "-DBBF_VENDOR_PREFIX=\\\"X_IOPSYS_EU_\\\"" CFLAGS: "-DBBF_VENDOR_PREFIX=\\\"X_IOWRT_EU_\\\""
DEBUG: 'TRUE' DEBUG: 'TRUE'
SOURCE_FOLDER: "." SOURCE_FOLDER: "."
COMPILATION_FIXUP: "cmake ." COMPILATION_FIXUP: "cmake ."

View file

@ -8,8 +8,8 @@ pwd
trap cleanup EXIT trap cleanup EXIT
trap cleanup SIGINT trap cleanup SIGINT
echo "Add X_IOPSYS_EU_Dropbear Object that is needed for functional test" echo "Add X_IOWRT_EU_Dropbear Object that is needed for functional test"
DROPBEAR_OBJECT='{"parent_dm": "Device.", "object": "X_IOPSYS_EU_Dropbear"}' DROPBEAR_OBJECT='{"parent_dm": "Device.", "object": "X_IOWRT_EU_Dropbear"}'
jq --argjson newObj "$DROPBEAR_OBJECT" '.daemon.services += [$newObj]' "/etc/bbfdm/services/core.json" > /tmp/updated_core.json jq --argjson newObj "$DROPBEAR_OBJECT" '.daemon.services += [$newObj]' "/etc/bbfdm/services/core.json" > /tmp/updated_core.json
mv /tmp/updated_core.json /etc/bbfdm/services/core.json mv /tmp/updated_core.json /etc/bbfdm/services/core.json

View file

@ -1,7 +1,7 @@
{ {
"custom_notification": [ "custom_notification": [
{ {
"parameter": "Device.X_IOPSYS_EU_Dropbear.", "parameter": "Device.X_IOWRT_EU_Dropbear.",
"notify_type": "2" "notify_type": "2"
}, },
{ {

View file

@ -1,7 +1,7 @@
{ {
"custom_notification": "custom_notification":
{ {
"parameter": "Device.X_IOPSYS_EU_Dropbear.", "parameter": "Device.X_IOWRT_EU_Dropbear.",
"notify_type": "2" "notify_type": "2"
}, },
{ {

View file

@ -1,7 +1,7 @@
{ {
"custom_notification": [ "custom_notification": [
{ {
"parameter": "Device.X_IOPSYS_EU_Dropbear.", "parameter": "Device.X_IOWRT_EU_Dropbear.",
"notify_type": "2" "notify_type": "2"
}, },
{ {

View file

@ -1,7 +1,7 @@
{ {
"custom_notification": [ "custom_notification": [
{ {
"parameter": "Device.X_IOPSYS_EU_Dropbear.", "parameter": "Device.X_IOWRT_EU_Dropbear.",
"notify_type": "2" "notify_type": "2"
}, },
{ {

View file

@ -8,7 +8,7 @@ TEST_NAME="ADD RPC Method"
echo "Running: $TEST_NAME" echo "Running: $TEST_NAME"
remove_icwmp_log remove_icwmp_log
curl $connection_request_path -X POST --data '{"name": "addObject","objectName":"Device.X_IOPSYS_EU_Dropbear"}' >/dev/null 2>&1 curl $connection_request_path -X POST --data '{"name": "addObject","objectName":"Device.X_IOWRT_EU_Dropbear"}' >/dev/null 2>&1
check_ret $? check_ret $?
wait_for_session_end wait_for_session_end
@ -22,7 +22,7 @@ if [ "$obj_instance" != "2" -o $status != "0" ]; then
fi fi
remove_icwmp_log remove_icwmp_log
curl $connection_request_path -X POST --data '{"name": "getParameterValues", "parameterNames": ["Device.X_IOPSYS_EU_Dropbear.2"] }' >/dev/null 2>&1 curl $connection_request_path -X POST --data '{"name": "getParameterValues", "parameterNames": ["Device.X_IOWRT_EU_Dropbear.2"] }' >/dev/null 2>&1
check_ret $? check_ret $?
wait_for_session_end wait_for_session_end

View file

@ -8,7 +8,7 @@ TEST_NAME="DELETE RPC Method"
echo "Running: $TEST_NAME" echo "Running: $TEST_NAME"
remove_icwmp_log remove_icwmp_log
curl $connection_request_path -X POST --data '{"name": "deleteObject","objectName":"Device.X_IOPSYS_EU_Dropbear.2"}' >/dev/null 2>&1 curl $connection_request_path -X POST --data '{"name": "deleteObject","objectName":"Device.X_IOWRT_EU_Dropbear.2"}' >/dev/null 2>&1
check_ret $? check_ret $?
wait_for_session_end wait_for_session_end
check_session "DeleteObject" check_session "DeleteObject"
@ -19,12 +19,12 @@ if [ "$status" != "1" ]; then
fi fi
remove_icwmp_log remove_icwmp_log
curl $connection_request_path -X POST --data '{"name": "getParameterValues", "parameterNames": ["Device.X_IOPSYS_EU_Dropbear"] }' >/dev/null 2>&1 curl $connection_request_path -X POST --data '{"name": "getParameterValues", "parameterNames": ["Device.X_IOWRT_EU_Dropbear"] }' >/dev/null 2>&1
check_ret $? check_ret $?
wait_for_session_end wait_for_session_end
check_session "GetParameterValues" check_session "GetParameterValues"
if grep -q "Device.X_IOPSYS_EU_Dropbear.2" "$icwmp_log_file"; then if grep -q "Device.X_IOWRT_EU_Dropbear.2" "$icwmp_log_file"; then
echo "Error: 'Device.X_IOPSYS_EU_Dropbear.2' object is not really deleted" >> ./funl-test-debug.log echo "Error: 'Device.X_IOWRT_EU_Dropbear.2' object is not really deleted" >> ./funl-test-debug.log
exit 1 exit 1
fi fi

View file

@ -8,13 +8,13 @@ TEST_NAME="GET RPC Method"
echo "Running: $TEST_NAME" echo "Running: $TEST_NAME"
remove_icwmp_log remove_icwmp_log
curl $connection_request_path -X POST --data '{"name": "getParameterValues", "parameterNames": ["Device.X_IOPSYS_EU_Dropbear.1.Alias"] }' >/dev/null 2>&1 curl $connection_request_path -X POST --data '{"name": "getParameterValues", "parameterNames": ["Device.X_IOWRT_EU_Dropbear.1.Alias"] }' >/dev/null 2>&1
check_ret $? check_ret $?
wait_for_session_end wait_for_session_end
check_session "GetParameterValues" check_session "GetParameterValues"
param_value=$(print_tag_value "cwmp:GetParameterValuesResponse" "Value xsi:type=\"xsd:string\"") param_value=$(print_tag_value "cwmp:GetParameterValuesResponse" "Value xsi:type=\"xsd:string\"")
if [ "$param_value" != "cpe-1" ]; then if [ "$param_value" != "cpe-1" ]; then
echo "Error: Default value of 'Device.X_IOPSYS_EU_Dropbear.1.Alias' is wrong, current_value($param_value) expected_value(cpe-1)" >> ./funl-test-debug.log echo "Error: Default value of 'Device.X_IOWRT_EU_Dropbear.1.Alias' is wrong, current_value($param_value) expected_value(cpe-1)" >> ./funl-test-debug.log
exit 1 exit 1
fi fi

View file

@ -8,18 +8,18 @@ TEST_NAME="SET RPC Method"
echo "Running: $TEST_NAME" echo "Running: $TEST_NAME"
remove_icwmp_log remove_icwmp_log
curl $connection_request_path -X POST --data '{"name": "getParameterValues", "parameterNames": ["Device.X_IOPSYS_EU_Dropbear.1.PasswordAuth"] }' >/dev/null 2>&1 curl $connection_request_path -X POST --data '{"name": "getParameterValues", "parameterNames": ["Device.X_IOWRT_EU_Dropbear.1.PasswordAuth"] }' >/dev/null 2>&1
check_ret $? check_ret $?
wait_for_session_end wait_for_session_end
check_session "GetParameterValues" check_session "GetParameterValues"
param_value_before=$(print_tag_value "cwmp:GetParameterValuesResponse" "Value xsi:type=\"xsd:boolean\"") param_value_before=$(print_tag_value "cwmp:GetParameterValuesResponse" "Value xsi:type=\"xsd:boolean\"")
if [ "$param_value_before" != "1" ]; then if [ "$param_value_before" != "1" ]; then
echo "Error: Default value of 'Device.X_IOPSYS_EU_Dropbear.1.PasswordAuth' is wrong, current_value($param_value_before) expected_value(1)" >> ./funl-test-debug.log echo "Error: Default value of 'Device.X_IOWRT_EU_Dropbear.1.PasswordAuth' is wrong, current_value($param_value_before) expected_value(1)" >> ./funl-test-debug.log
exit 1 exit 1
fi fi
remove_icwmp_log remove_icwmp_log
curl $connection_request_path -X POST --data '{"name": "setParameterValues", "parameterValues": [["Device.X_IOPSYS_EU_Dropbear.1.PasswordAuth",false]]}' >/dev/null 2>&1 curl $connection_request_path -X POST --data '{"name": "setParameterValues", "parameterValues": [["Device.X_IOWRT_EU_Dropbear.1.PasswordAuth",false]]}' >/dev/null 2>&1
check_ret $? check_ret $?
wait_for_session_end wait_for_session_end
check_session "SetParameterValues" check_session "SetParameterValues"
@ -30,17 +30,17 @@ if [ "$get_status" != "0" ]; then
fi fi
remove_icwmp_log remove_icwmp_log
curl $connection_request_path -X POST --data '{"name": "getParameterValues", "parameterNames": ["Device.X_IOPSYS_EU_Dropbear.1.PasswordAuth"] }' >/dev/null 2>&1 curl $connection_request_path -X POST --data '{"name": "getParameterValues", "parameterNames": ["Device.X_IOWRT_EU_Dropbear.1.PasswordAuth"] }' >/dev/null 2>&1
check_ret $? check_ret $?
wait_for_session_end wait_for_session_end
check_session "GetParameterValues" check_session "GetParameterValues"
param_value_after=$(print_tag_value "cwmp:GetParameterValuesResponse" "Value xsi:type=\"xsd:boolean\"") param_value_after=$(print_tag_value "cwmp:GetParameterValuesResponse" "Value xsi:type=\"xsd:boolean\"")
if [ "$param_value_after" != "0" ]; then if [ "$param_value_after" != "0" ]; then
echo "Error: the value of 'Device.X_IOPSYS_EU_Dropbear.1.PasswordAuth' is wrong, current_value($param_value_after) expected_value(0)" >> ./funl-test-debug.log echo "Error: the value of 'Device.X_IOWRT_EU_Dropbear.1.PasswordAuth' is wrong, current_value($param_value_after) expected_value(0)" >> ./funl-test-debug.log
exit 1 exit 1
fi fi
curl $connection_request_path -X POST --data '{"name": "setParameterValues", "parameterValues": [["Device.X_IOPSYS_EU_Dropbear.1.PasswordAuth",true]]}' >/dev/null 2>&1 curl $connection_request_path -X POST --data '{"name": "setParameterValues", "parameterValues": [["Device.X_IOWRT_EU_Dropbear.1.PasswordAuth",true]]}' >/dev/null 2>&1
wait_for_session_end wait_for_session_end
echo "PASS: $TEST_NAME" echo "PASS: $TEST_NAME"

View file

@ -99,8 +99,8 @@ if [[ $res != *"9009"* ]]; then
fi fi
log "ADD METHOD: Correct Path" log "ADD METHOD: Correct Path"
res=$(./icwmpd -c add Device.X_IOPSYS_EU_Dropbear. 2>&1) res=$(./icwmpd -c add Device.X_IOWRT_EU_Dropbear. 2>&1)
if [[ $res != *"Device.X_IOPSYS_EU_Dropbear."* ]]; then if [[ $res != *"Device.X_IOWRT_EU_Dropbear."* ]]; then
log "Error: Add Method with correct path doesn't work correctly" log "Error: Add Method with correct path doesn't work correctly"
exit 1 exit 1
fi fi
@ -129,7 +129,7 @@ if [[ $res != *"Deleted ${del_path}"* ]]; then
fi fi
log "DELETE METHOD: Correct Path && all instance" log "DELETE METHOD: Correct Path && all instance"
res=$(./icwmpd -c del Device.X_IOPSYS_EU_Dropbear. 2>&1) res=$(./icwmpd -c del Device.X_IOWRT_EU_Dropbear. 2>&1)
if [[ $res != *"9005"* ]]; then if [[ $res != *"9005"* ]]; then
log "Error: Delete Method with correct path && all instances doesn't work correctly" log "Error: Delete Method with correct path && all instances doesn't work correctly"
exit 1 exit 1

View file

@ -27,9 +27,9 @@ supervisorctl stop icwmpd
check_valgrind_xml check_valgrind_xml
notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOPSYS_EU_Dropbear."` notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOWRT_EU_Dropbear."`
if [[ $notif1 != *"Device.X_IOPSYS_EU_Dropbear."* ]]; then if [[ $notif1 != *"Device.X_IOWRT_EU_Dropbear."* ]]; then
echo "FAIL: active notifications list doesn't contain Device.X_IOPSYS_EU_Dropbear. parameter" echo "FAIL: active notifications list doesn't contain Device.X_IOWRT_EU_Dropbear. parameter"
exit 1 exit 1
fi fi
notif2=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].passive | grep "Device.WiFi.SSID.1.SSID"` notif2=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].passive | grep "Device.WiFi.SSID.1.SSID"`
@ -60,9 +60,9 @@ supervisorctl stop icwmpd
check_valgrind_xml check_valgrind_xml
notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOPSYS_EU_Dropbear."` notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOWRT_EU_Dropbear."`
if [[ $notif1 == *"Device.X_IOPSYS_EU_Dropbear."* ]]; then if [[ $notif1 == *"Device.X_IOWRT_EU_Dropbear."* ]]; then
echo "FAIL: the json file is invalid, the active notifcation list shouldn't contain Device.X_IOPSYS_EU_Dropbear. parameter" echo "FAIL: the json file is invalid, the active notifcation list shouldn't contain Device.X_IOWRT_EU_Dropbear. parameter"
exit 1 exit 1
fi fi
notif2=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].passive | grep "Device.WiFi.SSID.1.SSID"` notif2=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].passive | grep "Device.WiFi.SSID.1.SSID"`
@ -98,9 +98,9 @@ supervisorctl stop icwmpd
check_valgrind_xml check_valgrind_xml
notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOPSYS_EU_Dropbear."` notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOWRT_EU_Dropbear."`
if [[ $notif1 != *"Device.X_IOPSYS_EU_Dropbear."* ]]; then if [[ $notif1 != *"Device.X_IOWRT_EU_Dropbear."* ]]; then
echo "FAIL: active notifications list doesn't contain Device.X_IOPSYS_EU_Dropbear. parameter" echo "FAIL: active notifications list doesn't contain Device.X_IOWRT_EU_Dropbear. parameter"
exit 1 exit 1
fi fi
notif2=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].passive | grep "Device.DeviceInfo.ProvisioningCode"` notif2=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].passive | grep "Device.DeviceInfo.ProvisioningCode"`
@ -136,9 +136,9 @@ supervisorctl stop icwmpd
check_valgrind_xml check_valgrind_xml
notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOPSYS_EU_Dropbear."` notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOWRT_EU_Dropbear."`
if [[ $notif1 != *"Device.X_IOPSYS_EU_Dropbear."* ]]; then if [[ $notif1 != *"Device.X_IOWRT_EU_Dropbear."* ]]; then
echo "FAIL: active notifications list doesn't contain Device.X_IOPSYS_EU_Dropbear. parameter" echo "FAIL: active notifications list doesn't contain Device.X_IOWRT_EU_Dropbear. parameter"
exit 1 exit 1
fi fi
notif2=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].passive | grep "Device.WiFi.SSID.1.SD"` notif2=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].passive | grep "Device.WiFi.SSID.1.SD"`