diff --git a/functional_tests/features/searx.feature b/functional_tests/features/searx.feature index daf78749e..50e776038 100644 --- a/functional_tests/features/searx.feature +++ b/functional_tests/features/searx.feature @@ -15,7 +15,7 @@ # along with this program. If not, see . # -@apps @searx +@apps @searx @backups Feature: Searx Web Search Run Searx metasearch engine. @@ -32,3 +32,10 @@ Scenario: Disable searx application Given the searx application is enabled When I disable the searx application Then the searx site should not be available + +Scenario: Backup and restore searx + Given the searx application is enabled + When I create a backup of the searx app data + And I export the searx app data backup + And I restore the searx app data backup + Then the searx site should be available diff --git a/plinth/modules/searx/__init__.py b/plinth/modules/searx/__init__.py index e4810a6e5..7195506b2 100644 --- a/plinth/modules/searx/__init__.py +++ b/plinth/modules/searx/__init__.py @@ -27,7 +27,7 @@ from plinth import action_utils, actions, frontpage from plinth.menu import main_menu from plinth.modules.users import register_group -from .manifest import clients +from .manifest import backup, clients clients = clients diff --git a/plinth/modules/searx/manifest.py b/plinth/modules/searx/manifest.py index d908ae416..aa0e76f3a 100644 --- a/plinth/modules/searx/manifest.py +++ b/plinth/modules/searx/manifest.py @@ -18,6 +18,7 @@ from django.utils.translation import ugettext_lazy as _ from plinth.clients import validate +from plinth.modules.backups.api import validate as validate_backup clients = validate([{ 'name': _('Searx'), @@ -26,3 +27,5 @@ clients = validate([{ 'url': '/searx/' }] }]) + +backup = validate_backup({})