mirror of
https://dev.iopsys.eu/bbf/icwmp.git
synced 2025-12-09 23:34:41 +01:00
Update vendor extension in pipeline
This commit is contained in:
parent
6e80cefd00
commit
8bb5c68295
12 changed files with 36 additions and 36 deletions
|
|
@ -1,5 +1,5 @@
|
|||
variables:
|
||||
CFLAGS: "-DBBF_VENDOR_PREFIX=\\\"X_IOPSYS_EU_\\\""
|
||||
CFLAGS: "-DBBF_VENDOR_PREFIX=\\\"X_IOWRT_EU_\\\""
|
||||
DEBUG: 'TRUE'
|
||||
SOURCE_FOLDER: "."
|
||||
COMPILATION_FIXUP: "cmake ."
|
||||
|
|
|
|||
|
|
@ -8,8 +8,8 @@ pwd
|
|||
trap cleanup EXIT
|
||||
trap cleanup SIGINT
|
||||
|
||||
echo "Add X_IOPSYS_EU_Dropbear Object that is needed for functional test"
|
||||
DROPBEAR_OBJECT='{"parent_dm": "Device.", "object": "X_IOPSYS_EU_Dropbear"}'
|
||||
echo "Add X_IOWRT_EU_Dropbear Object that is needed for functional test"
|
||||
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
|
||||
mv /tmp/updated_core.json /etc/bbfdm/services/core.json
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"custom_notification": [
|
||||
{
|
||||
"parameter": "Device.X_IOPSYS_EU_Dropbear.",
|
||||
"parameter": "Device.X_IOWRT_EU_Dropbear.",
|
||||
"notify_type": "2"
|
||||
},
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"custom_notification":
|
||||
{
|
||||
"parameter": "Device.X_IOPSYS_EU_Dropbear.",
|
||||
"parameter": "Device.X_IOWRT_EU_Dropbear.",
|
||||
"notify_type": "2"
|
||||
},
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"custom_notification": [
|
||||
{
|
||||
"parameter": "Device.X_IOPSYS_EU_Dropbear.",
|
||||
"parameter": "Device.X_IOWRT_EU_Dropbear.",
|
||||
"notify_type": "2"
|
||||
},
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"custom_notification": [
|
||||
{
|
||||
"parameter": "Device.X_IOPSYS_EU_Dropbear.",
|
||||
"parameter": "Device.X_IOWRT_EU_Dropbear.",
|
||||
"notify_type": "2"
|
||||
},
|
||||
{
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ TEST_NAME="ADD RPC Method"
|
|||
echo "Running: $TEST_NAME"
|
||||
|
||||
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 $?
|
||||
|
||||
wait_for_session_end
|
||||
|
|
@ -22,7 +22,7 @@ if [ "$obj_instance" != "2" -o $status != "0" ]; then
|
|||
fi
|
||||
|
||||
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 $?
|
||||
|
||||
wait_for_session_end
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ TEST_NAME="DELETE RPC Method"
|
|||
echo "Running: $TEST_NAME"
|
||||
|
||||
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 $?
|
||||
wait_for_session_end
|
||||
check_session "DeleteObject"
|
||||
|
|
@ -19,12 +19,12 @@ if [ "$status" != "1" ]; then
|
|||
fi
|
||||
|
||||
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 $?
|
||||
wait_for_session_end
|
||||
check_session "GetParameterValues"
|
||||
if grep -q "Device.X_IOPSYS_EU_Dropbear.2" "$icwmp_log_file"; then
|
||||
echo "Error: 'Device.X_IOPSYS_EU_Dropbear.2' object is not really deleted" >> ./funl-test-debug.log
|
||||
if grep -q "Device.X_IOWRT_EU_Dropbear.2" "$icwmp_log_file"; then
|
||||
echo "Error: 'Device.X_IOWRT_EU_Dropbear.2' object is not really deleted" >> ./funl-test-debug.log
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
|
|
|||
|
|
@ -8,13 +8,13 @@ TEST_NAME="GET RPC Method"
|
|||
echo "Running: $TEST_NAME"
|
||||
|
||||
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 $?
|
||||
wait_for_session_end
|
||||
check_session "GetParameterValues"
|
||||
param_value=$(print_tag_value "cwmp:GetParameterValuesResponse" "Value xsi:type=\"xsd:string\"")
|
||||
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
|
||||
fi
|
||||
|
||||
|
|
|
|||
|
|
@ -8,18 +8,18 @@ TEST_NAME="SET RPC Method"
|
|||
echo "Running: $TEST_NAME"
|
||||
|
||||
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 $?
|
||||
wait_for_session_end
|
||||
check_session "GetParameterValues"
|
||||
param_value_before=$(print_tag_value "cwmp:GetParameterValuesResponse" "Value xsi:type=\"xsd:boolean\"")
|
||||
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
|
||||
fi
|
||||
|
||||
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 $?
|
||||
wait_for_session_end
|
||||
check_session "SetParameterValues"
|
||||
|
|
@ -30,17 +30,17 @@ if [ "$get_status" != "0" ]; then
|
|||
fi
|
||||
|
||||
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 $?
|
||||
wait_for_session_end
|
||||
check_session "GetParameterValues"
|
||||
param_value_after=$(print_tag_value "cwmp:GetParameterValuesResponse" "Value xsi:type=\"xsd:boolean\"")
|
||||
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
|
||||
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
|
||||
|
||||
echo "PASS: $TEST_NAME"
|
||||
|
|
|
|||
|
|
@ -99,8 +99,8 @@ if [[ $res != *"9009"* ]]; then
|
|||
fi
|
||||
|
||||
log "ADD METHOD: Correct Path"
|
||||
res=$(./icwmpd -c add Device.X_IOPSYS_EU_Dropbear. 2>&1)
|
||||
if [[ $res != *"Device.X_IOPSYS_EU_Dropbear."* ]]; then
|
||||
res=$(./icwmpd -c add Device.X_IOWRT_EU_Dropbear. 2>&1)
|
||||
if [[ $res != *"Device.X_IOWRT_EU_Dropbear."* ]]; then
|
||||
log "Error: Add Method with correct path doesn't work correctly"
|
||||
exit 1
|
||||
fi
|
||||
|
|
@ -129,7 +129,7 @@ if [[ $res != *"Deleted ${del_path}"* ]]; then
|
|||
fi
|
||||
|
||||
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
|
||||
log "Error: Delete Method with correct path && all instances doesn't work correctly"
|
||||
exit 1
|
||||
|
|
|
|||
|
|
@ -27,9 +27,9 @@ supervisorctl stop icwmpd
|
|||
|
||||
check_valgrind_xml
|
||||
|
||||
notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOPSYS_EU_Dropbear."`
|
||||
if [[ $notif1 != *"Device.X_IOPSYS_EU_Dropbear."* ]]; then
|
||||
echo "FAIL: active notifications list doesn't contain Device.X_IOPSYS_EU_Dropbear. parameter"
|
||||
notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOWRT_EU_Dropbear."`
|
||||
if [[ $notif1 != *"Device.X_IOWRT_EU_Dropbear."* ]]; then
|
||||
echo "FAIL: active notifications list doesn't contain Device.X_IOWRT_EU_Dropbear. parameter"
|
||||
exit 1
|
||||
fi
|
||||
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
|
||||
|
||||
notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOPSYS_EU_Dropbear."`
|
||||
if [[ $notif1 == *"Device.X_IOPSYS_EU_Dropbear."* ]]; then
|
||||
echo "FAIL: the json file is invalid, the active notifcation list shouldn't contain Device.X_IOPSYS_EU_Dropbear. parameter"
|
||||
notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOWRT_EU_Dropbear."`
|
||||
if [[ $notif1 == *"Device.X_IOWRT_EU_Dropbear."* ]]; then
|
||||
echo "FAIL: the json file is invalid, the active notifcation list shouldn't contain Device.X_IOWRT_EU_Dropbear. parameter"
|
||||
exit 1
|
||||
fi
|
||||
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
|
||||
|
||||
notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOPSYS_EU_Dropbear."`
|
||||
if [[ $notif1 != *"Device.X_IOPSYS_EU_Dropbear."* ]]; then
|
||||
echo "FAIL: active notifications list doesn't contain Device.X_IOPSYS_EU_Dropbear. parameter"
|
||||
notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOWRT_EU_Dropbear."`
|
||||
if [[ $notif1 != *"Device.X_IOWRT_EU_Dropbear."* ]]; then
|
||||
echo "FAIL: active notifications list doesn't contain Device.X_IOWRT_EU_Dropbear. parameter"
|
||||
exit 1
|
||||
fi
|
||||
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
|
||||
|
||||
notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOPSYS_EU_Dropbear."`
|
||||
if [[ $notif1 != *"Device.X_IOPSYS_EU_Dropbear."* ]]; then
|
||||
echo "FAIL: active notifications list doesn't contain Device.X_IOPSYS_EU_Dropbear. parameter"
|
||||
notif1=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].active | grep "Device.X_IOWRT_EU_Dropbear."`
|
||||
if [[ $notif1 != *"Device.X_IOWRT_EU_Dropbear."* ]]; then
|
||||
echo "FAIL: active notifications list doesn't contain Device.X_IOWRT_EU_Dropbear. parameter"
|
||||
exit 1
|
||||
fi
|
||||
notif2=`uci -c /etc/icwmpd get cwmp_notifications.@notifications[0].passive | grep "Device.WiFi.SSID.1.SD"`
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue