From 13a3d4ccd57e00ff54d9f00af4b60aced1f84770 Mon Sep 17 00:00:00 2001
From: Mariia Azbeleva <mariia.azbeleva@unikie.com>
Date: Mon, 14 Oct 2024 13:52:17 +0300
Subject: [PATCH] Add test wifi credentials

Signed-off-by: Mariia Azbeleva <mariia.azbeleva@unikie.com>
---
 ghaf-hw-test.groovy          | 4 ++++
 ghaf-parallel-hw-test.groovy | 4 ++++
 2 files changed, 8 insertions(+)

diff --git a/ghaf-hw-test.groovy b/ghaf-hw-test.groovy
index 3b3bcb6..306f774 100644
--- a/ghaf-hw-test.groovy
+++ b/ghaf-hw-test.groovy
@@ -50,6 +50,8 @@ def ghaf_robot_test(String testname='boot') {
     string(credentialsId: 'testagent-plug-pass', variable: 'PLUG_PASS'),
     string(credentialsId: 'testagent-switch-token', variable: 'SW_TOKEN'),
     string(credentialsId: 'testagent-switch-secret', variable: 'SW_SECRET'),
+    string(credentialsId: 'testagent-wifi-ssid', variable: 'WIFI_SSID'),
+    string(credentialsId: 'testagent-wifi-password', variable: 'WIFI_PSWD'),
     ]) {
     dir("Robot-Framework/test-suites") {
       sh 'rm -f *.png output.xml report.html log.html'
@@ -70,6 +72,8 @@ def ghaf_robot_test(String testname='boot') {
             -v SWITCH_TOKEN:$SW_TOKEN \
             -v SWITCH_SECRET:$SW_SECRET \
             -v BUILD_ID:${BUILD_NUMBER} \
+            -v TEST_WIFI_SSID:${WIFI_SSID} \
+            -v TEST_WIFI_PSWD:${WIFI_PSWD} \
             -i $INCLUDE_TEST_TAGS .
         '''
         if (testname == 'boot') {
diff --git a/ghaf-parallel-hw-test.groovy b/ghaf-parallel-hw-test.groovy
index 943fe5a..fc38d08 100644
--- a/ghaf-parallel-hw-test.groovy
+++ b/ghaf-parallel-hw-test.groovy
@@ -49,6 +49,8 @@ def ghaf_robot_test(String testname='boot') {
     string(credentialsId: 'testagent-plug-pass', variable: 'PLUG_PASS'),
     string(credentialsId: 'testagent-switch-token', variable: 'SW_TOKEN'),
     string(credentialsId: 'testagent-switch-secret', variable: 'SW_SECRET'),
+    string(credentialsId: 'testagent-wifi-ssid', variable: 'WIFI_SSID'),
+    string(credentialsId: 'testagent-wifi-password', variable: 'WIFI_PSWD'),
     ]) {
     dir("Robot-Framework/test-suites") {
       sh 'rm -f *.png output.xml report.html log.html'
@@ -69,6 +71,8 @@ def ghaf_robot_test(String testname='boot') {
             -v SWITCH_TOKEN:$SW_TOKEN \
             -v SWITCH_SECRET:$SW_SECRET \
             -v BUILD_ID:${BUILD_NUMBER} \
+            -v TEST_WIFI_SSID:${WIFI_SSID} \
+            -v TEST_WIFI_PSWD:${WIFI_PSWD} \
             -i $INCLUDE_TEST_TAGS .
         '''
         if (testname == 'boot') {