MDL-69906 admin: Display Setup search engine as link only if it is valid
[moodle.git] / search / tests / behat / setup_search_engine.feature
CommitLineData
bda1473a
DM
1@core @core_search
2Feature: Plugins > Search > Search setup contains Setup search engine only if the target section actually exists
3 In order to set up the selected search engine
4 As an admin
5 I need to be able to click the link 'Setup search engine' but only if the target section actually exists
6
7 Scenario: Selected search engine has an admin section
8 Given the following config values are set as admin:
9 | enableglobalsearch | 1 |
10 | searchengine | solr |
11 And I log in as "admin"
12 When I navigate to "Plugins > Search" in site administration
13 Then "Setup search engine" "link" should exist
14
15 Scenario: Selected search engine does not have an admin section
16 Given the following config values are set as admin:
17 | enableglobalsearch | 1 |
18 | searchengine | simpledb |
19 And I log in as "admin"
20 When I navigate to "Plugins > Search" in site administration
21 Then I should see "Setup search engine"
22 And "Setup search engine" "link" should not exist