Skip to content

Commit 7693345

Browse files
author
Matthias Opitz
committed
add Behat test
1 parent 42dba87 commit 7693345

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed

tests/behat/see_news.feature

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
@block @block_news @javascript
2+
Feature: Test that the news are visible on the home page
3+
As a teacher
4+
In order to be able be updated about news
5+
I need to be able to see the news items on the home page.
6+
7+
Background:
8+
Given the following "users" exist:
9+
| username |
10+
| teacher |
11+
And the following "courses" exist:
12+
| fullname | shortname | category |
13+
| Course 1 | C1 | 0 |
14+
And the following "course enrolments" exist:
15+
| user | course | role |
16+
| teacher | C1 | editingteacher |
17+
18+
Scenario: See the news items on the home page
19+
When I am on the "Course 1" course page logged in as admin
20+
And I click on "Home" "link"
21+
And I add the "News" block if not present
22+
# And I configure the "Navigation" block
23+
# And I set the following fields to these values:
24+
# | Page contexts | Display throughout the entire site |
25+
# And I press "Save changes"
26+
27+
Then I should see "Welcome back, teacher1!" in the "page-header" "region"
28+

0 commit comments

Comments
 (0)