diff --git a/test/system/libs/helpers.bash b/test/system/libs/helpers.bash index bb1b5e41f..3d407054e 100644 --- a/test/system/libs/helpers.bash +++ b/test/system/libs/helpers.bash @@ -494,7 +494,7 @@ function find_os_release() { # Returns the content of field ID in os-release -function get_system_id() { +function get_system_id() ( local os_release os_release="$(find_os_release)" @@ -505,8 +505,9 @@ function get_system_id() { return fi - echo $(awk -F= '/ID/ {print $2}' $os_release | head -n 1) -} + . "$os_release" + echo "$ID" +) # Returns the content of field VERSION_ID in os-release