From 7f7b5b4e675fa163f070bc13be6bb192187beb1d Mon Sep 17 00:00:00 2001 From: Sunil Mohan Adapa Date: Mon, 11 May 2020 22:26:45 -0700 Subject: [PATCH] performance: Add basic functional tests Signed-off-by: Sunil Mohan Adapa --- functional_tests/features/performance.feature | 20 +++++++++++++++++++ functional_tests/support/interface.py | 4 ++-- 2 files changed, 22 insertions(+), 2 deletions(-) create mode 100644 functional_tests/features/performance.feature diff --git a/functional_tests/features/performance.feature b/functional_tests/features/performance.feature new file mode 100644 index 000000000..cbae2c492 --- /dev/null +++ b/functional_tests/features/performance.feature @@ -0,0 +1,20 @@ +# SPDX-License-Identifier: AGPL-3.0-or-later + +@system @performance +Feature: Performance - system monitoring + Run the Performance Co-Pilot app. + +Background: + Given I'm a logged in user + And advanced mode is on + And the performance application is installed + +Scenario: Enable performance application + Given the performance application is disabled + When I enable the performance application + Then the performance service should be running + +Scenario: Disable performance application + Given the performance application is enabled + When I disable the performance application + Then the performance service should not be running diff --git a/functional_tests/support/interface.py b/functional_tests/support/interface.py index c9a4f23d9..fb8af4c28 100644 --- a/functional_tests/support/interface.py +++ b/functional_tests/support/interface.py @@ -13,8 +13,8 @@ from .service import wait_for_page_update sys_modules = [ 'avahi', 'backups', 'bind', 'cockpit', 'config', 'datetime', 'diagnostics', 'dynamicdns', 'firewall', 'letsencrypt', 'monkeysphere', 'names', - 'networks', 'pagekite', 'power', 'security', 'snapshot', 'ssh', 'storage', - 'upgrades', 'users' + 'networks', 'pagekite', 'performance', 'power', 'security', 'snapshot', + 'ssh', 'storage', 'upgrades', 'users' ] default_url = config['DEFAULT']['url']