diff options
author | Paul Boca <pboca@cloudbasesolutions.com> | 2016-06-07 08:12:16 +0000 |
---|---|---|
committer | Ben Pfaff <blp@ovn.org> | 2016-06-07 10:49:08 -0700 |
commit | ab7fc30e13b4f07acb659b6801d4f98ddba2f1a6 (patch) | |
tree | fe5c29c50ad1c7bd4bffc06b1ca20defe25c8773 /tests | |
parent | 4886d4d2495b4ca2864d98fa9d7198fac79abdd3 (diff) | |
download | openvswitch-ab7fc30e13b4f07acb659b6801d4f98ddba2f1a6.tar.gz |
tests: Skip "daemon --service" test on Windows from non-admin console
Check if we have enough rights to create a service on Windows
otherwise we skip daemon test
Signed-off-by: Paul-Daniel Boca <pboca@cloudbasesolutions.com>
Acked-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com>
Tested-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com>
Signed-off-by: Ben Pfaff <blp@ovn.org>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/daemon.at | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/daemon.at b/tests/daemon.at index 41c5d0785..962169a77 100644 --- a/tests/daemon.at +++ b/tests/daemon.at @@ -2,6 +2,15 @@ AT_BANNER([daemon unit tests - C]) AT_SETUP([daemon]) AT_SKIP_IF([test "$IS_WIN32" = "yes"]) + +dnl OVS_SKIP_NON_ADMIN_WIN() +dnl +dnl Checks if we have enough rights to create a service +m4_define([OVS_SKIP_NON_ADMIN_WIN], + [ + AT_SKIP_IF([net session; test $? -ne 0]) + ]) + OVSDB_INIT([db]) AT_CAPTURE_FILE([pid]) AT_CAPTURE_FILE([expected]) @@ -163,6 +172,8 @@ AT_CLEANUP AT_SETUP([daemon --service]) AT_KEYWORDS([windows-service]) AT_SKIP_IF([test "$IS_WIN32" != "yes"]) +OVS_SKIP_NON_ADMIN_WIN + OVSDB_INIT([db]) AT_CAPTURE_FILE([pid]) # To create a Windows service, we need the absolute path for the executable. |