Skip to content

Commit

Permalink
Merge pull request #3882 from crazyserver/MOBILE-3947
Browse files Browse the repository at this point in the history
Mobile 3947
  • Loading branch information
dpalou authored Dec 15, 2023
2 parents a2f49c5 + a424923 commit f100e59
Show file tree
Hide file tree
Showing 25 changed files with 48 additions and 7 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/acceptance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
behat_tags:
description: 'Behat tags to execute'
required: true
default: '~@performance'
default: '~@performance&&~@ionic7_failure'
moodle_branch:
description: 'Moodle branch'
required: true
Expand All @@ -27,7 +27,7 @@ jobs:
MOODLE_DOCKER_PHP_VERSION: '8.1'
MOODLE_BRANCH: ${{ github.event.inputs.moodle_branch || 'master' }}
MOODLE_REPOSITORY: ${{ github.event.inputs.moodle_repository || 'https://github.com/moodle/moodle' }}
BEHAT_TAGS: ${{ github.event.inputs.behat_tags || '~@performance' }}
BEHAT_TAGS: ${{ github.event.inputs.behat_tags || '~@performance&&~@ionic7_failure' }}

steps:
- uses: actions/checkout@v2
Expand Down
2 changes: 1 addition & 1 deletion src/addons/block/timeline/tests/behat/basic_usage.feature
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ Feature: Timeline block.
| assign | C3 | assign24 | Assignment 24 | ##+1 year## |
| assign | C3 | assign25 | Assignment 25 | ##+1 year## |

@lms_from4.0
@lms_from4.0 @ionic7_failure
Scenario: See courses inside block
Given I entered the app as "student1"
Then I should find "Assignment 00" within "Timeline" "ion-card" in the app
Expand Down
1 change: 1 addition & 0 deletions src/addons/calendar/tests/behat/create_events.feature
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ Feature: Test creation of calendar events in app
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |

@ionic7_failure
Scenario: Create user event as student from monthly view
Given I entered the app as "student1"
When I press "More" in the app
Expand Down
2 changes: 2 additions & 0 deletions src/addons/competency/tests/behat/navigation.feature
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,7 @@ Feature: Test competency navigation
Then I should find "Desserts are important" in the app
But I should not find "Cakes" in the app

@ionic7_failure
Scenario: Tablet navigation (student)
Given I entered the course "Course 1" as "student1" in the app
And I change viewport size to "1200x640" in the app
Expand Down Expand Up @@ -382,6 +383,7 @@ Feature: Test competency navigation
Then I should find "Desserts are important" in the app
But I should not find "Cakes" in the app

@ionic7_failure
Scenario: Tablet navigation (teacher)
Given I entered the course "Course 1" as "teacher1" in the app
And I change viewport size to "1200x640" in the app
Expand Down
5 changes: 5 additions & 0 deletions src/addons/messages/tests/behat/basic_usage.feature
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ Feature: Test basic usage of messages in app
| student1 | C1 | student |
| student2 | C1 | student |

@ionic7_failure
Scenario: View recent conversations and contacts
Given I entered the app as "teacher1"
When I press "Messages" in the app
Expand Down Expand Up @@ -216,6 +217,7 @@ Feature: Test basic usage of messages in app
Then I should find "heeey student" in the app
And I should find "byee" in the app

@ionic7_failure
Scenario: Search for messages
Given I entered the app as "teacher1"
When I press "Messages" in the app
Expand Down Expand Up @@ -280,6 +282,7 @@ Feature: Test basic usage of messages in app
Then I should find "Teacher teacher" in the app
And I should find "Student1 student1" in the app

@ionic7_failure
Scenario: User blocking feature
Given I entered the course "Course 1" as "student2" in the app
When I press "Participants" in the app
Expand Down Expand Up @@ -317,6 +320,7 @@ Feature: Test basic usage of messages in app
Then I should find "test message" in the app
But I should not find "You are unable to message this user" in the app

@ionic7_failure
Scenario: Mute Unmute conversations
Given I entered the course "Course 1" as "student1" in the app
When I press "Participants" in the app
Expand Down Expand Up @@ -344,6 +348,7 @@ Feature: Test basic usage of messages in app
Then I should find "test message" in the app
And I should find "Muted conversation" in the app

@ionic7_failure
Scenario: Self conversations
Given I entered the app as "student1"
When I press "Messages" in the app
Expand Down
1 change: 1 addition & 0 deletions src/addons/messages/tests/behat/navigation.feature
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ Feature: Test messages navigation in the app
| teacher | C1 | editingteacher |
| student | C1 | student |

@ionic7_failure
Scenario: Avoid recursive links to profile
Given I entered the app as "teacher"
When I press "Messages" in the app
Expand Down
1 change: 1 addition & 0 deletions src/addons/mod/assign/tests/behat/basic_usage.feature
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ Feature: Test basic usage of assignment activity in app
Then I should find "Online text submissions" in the app
And I should find "Submission test edited" in the app

@ionic7_failure
Scenario: Edit/Add submission (online text) & Add new attempt from previous submission & Submit for grading
# Submit first attempt as a student
Given I entered the assign activity "assignment1" on course "Course 1" as "student1" in the app
Expand Down
6 changes: 6 additions & 0 deletions src/addons/mod/data/tests/behat/entries.feature
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ Feature: Users can manage entries in database activities
| data1 | text | URL | URL link |
| data1 | text | Description | Link description |

@ionic7_failure
Scenario: Create entry
Given I entered the data activity "Web links" on course "Course 1" as "student1" in the app
Then I should find "No entries yet" in the app
Expand All @@ -37,6 +38,7 @@ Feature: Users can manage entries in database activities
Then I should find "https://moodle.org/" in the app
And I should find "Moodle community site" in the app

@ionic7_failure
Scenario: Browse entry
Given I entered the data activity "Web links" on course "Course 1" as "student1" in the app

Expand Down Expand Up @@ -70,6 +72,7 @@ Feature: Users can manage entries in database activities
And I should find "Moodle community site" in the app
And I should find "Moodle Cloud" in the app

@ionic7_failure
Scenario: Students can not edit or delete other user's entries from list and single view in the app
Given I entered the data activity "Web links" on course "Course 1" as "student1" in the app
And I press "Add entries" in the app
Expand All @@ -85,6 +88,7 @@ Feature: Users can manage entries in database activities
And "Edit" "link" should not exist
And "Delete" "link" should not exist

@ionic7_failure
Scenario: Delete entry (student) & Update entry (student)
Given I entered the data activity "Web links" on course "Course 1" as "student1" in the app
And I press "Add entries" in the app
Expand Down Expand Up @@ -144,6 +148,7 @@ Feature: Users can manage entries in database activities
And I should not find "Moodle Cloud" in the app
And I should find "No entries yet" in the app

@ionic7_failure
Scenario: Delete entry (teacher) & Update entry (teacher)
Given I entered the data activity "Web links" on course "Course 1" as "student1" in the app
And I press "Add entries" in the app
Expand Down Expand Up @@ -207,6 +212,7 @@ Feature: Users can manage entries in database activities
And I press "Delete" in the app
And I should not find "Moodle Cloud" in the app

@ionic7_failure
Scenario: Handle number 0 correctly when creating entries
Given the following "activities" exist:
| activity | name | intro | course | idnumber |
Expand Down
3 changes: 3 additions & 0 deletions src/addons/mod/data/tests/behat/sync.feature
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ Feature: Users can store entries in database activities when offline and sync wh
| data1 | text | URL | URL link |
| data1 | text | Description | Link description |

@ionic7_failure
Scenario: Create entry (offline)
Given I entered the data activity "Web links" on course "Course 1" as "student1" in the app
And I switch network connection to offline
Expand All @@ -45,6 +46,7 @@ Feature: Users can store entries in database activities when offline and sync wh
And I should find "Moodle community site" in the app
And I should not find "This Database has offline data to be synchronised" in the app

@ionic7_failure
Scenario: Update entry (offline) & Delete entry (offline)
Given I entered the data activity "Web links" on course "Course 1" as "student1" in the app
And I should find "No entries yet" in the app
Expand Down Expand Up @@ -95,6 +97,7 @@ Feature: Users can store entries in database activities when offline and sync wh
And I should not find "Moodle Cloud" in the app
And I should not find "This Database has offline data to be synchronised" in the app

@ionic7_failure
Scenario: Students can undo deleting entries to a database in the app while offline
Given I entered the data activity "Web links" on course "Course 1" as "student1" in the app
And I should find "No entries yet" in the app
Expand Down
2 changes: 2 additions & 0 deletions src/addons/mod/forum/tests/behat/basic_usage.feature
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ Feature: Test basic usage of forum activity in app
Then I should find "My happy subject" in the app
And I should find "An awesome message" inside the split-view content in the app

@ionic7_failure
Scenario: Reply a post
Given I entered the forum activity "Test forum name" on course "Course 1" as "student1" in the app
When I replace "/.*/" within ".addon-mod-forum-discussion-author p" with "[Publication date]"
Expand Down Expand Up @@ -178,6 +179,7 @@ Feature: Test basic usage of forum activity in app
And I press "Save changes" in the app
Then I should find "Auto-test message edited" in the app

@ionic7_failure
Scenario: Delete a forum post (only online)
Given I entered the forum activity "Test forum name" on course "Course 1" as "student1" in the app
When I press "Add discussion topic" in the app
Expand Down
2 changes: 1 addition & 1 deletion src/addons/mod/glossary/tests/behat/navigation.feature
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ Feature: Test glossary navigation
And I should find "Cashew" in the app
And I should find "Acerola" in the app

@ci_jenkins_skip
@ci_jenkins_skip @ionic7_failure
Scenario: Tablet navigation on glossary
Given I entered the course "Course 1" as "student1" in the app
And I change viewport size to "1200x640" in the app
Expand Down
2 changes: 2 additions & 0 deletions src/addons/mod/quiz/tests/behat/basic_usage.feature
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,7 @@ Feature: Attempt a quiz in app
And I should find "Question 1" in the app
And I should find "Question 2" in the app

@ionic7_failure
Scenario: Attempt a quiz (all question types)
Given I entered the quiz activity "Quiz 2" on course "Course 1" as "student1" in the app
When I press "Attempt quiz now" in the app
Expand Down Expand Up @@ -190,6 +191,7 @@ Feature: Attempt a quiz in app
Then I should find "The correct answer is: Berlin" in the app
And I should find "Mark 1.00 out of 1.00" in the app

@ionic7_failure
Scenario: Submit a quiz & Review a quiz attempt
Given I entered the quiz activity "Quiz 1" on course "Course 1" as "student1" in the app
When I press "Attempt quiz now" in the app
Expand Down
4 changes: 4 additions & 0 deletions src/addons/mod/survey/tests/behat/basic_usage.feature
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ Feature: Test basic usage of survey activity in app
| activity | name | intro | course | idnumber | groupmode |
| survey | Test survey name | Test survey | C1 | survey | 0 |

@ionic7_failure
Scenario: Answer a survey & View results (ATTLS)
Given I entered the survey activity "Test survey name" on course "Course 1" as "student1" in the app
And I set the following fields to these values in the app:
Expand Down Expand Up @@ -78,6 +79,7 @@ Feature: Test basic usage of survey activity in app
And I should see "4th answer"
And I should see "5th answer"

@ionic7_failure
Scenario: Answer a survey & View results (Colles actual)
Given the following "activities" exist:
| activity | name | intro | template |course | idnumber | groupmode |
Expand Down Expand Up @@ -120,6 +122,7 @@ Feature: Test basic usage of survey activity in app
Then I should see "You've completed this survey. The graph below shows a summary of your results compared to the class averages."
And I should see "1 people have completed this survey so far"

@ionic7_failure
Scenario: Answer a survey & View results (Colles preferred)
Given the following "activities" exist:
| activity | name | intro | template | course | idnumber | groupmode |
Expand Down Expand Up @@ -162,6 +165,7 @@ Feature: Test basic usage of survey activity in app
Then I should see "You've completed this survey. The graph below shows a summary of your results compared to the class averages."
And I should see "1 people have completed this survey so far"

@ionic7_failure
Scenario: Answer a survey & View results (Colles preferred and actual)
Given the following "activities" exist:
| activity | name | intro | template | course | idnumber | groupmode |
Expand Down
1 change: 1 addition & 0 deletions src/addons/notifications/tests/behat/notifications.feature
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ Feature: Notifications
Then I should find "Test 10 description" in the app
But I should not find "Test 09 description" in the app

@ionic7_failure
Scenario: Tablet navigation
Given I enter the app
And I change viewport size to "1200x640" in the app
Expand Down
4 changes: 4 additions & 0 deletions src/core/features/comments/tests/behat/basic_usage.feature
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ Feature: Test basic usage of comments in app
| database | type | name | description |
| data1 | text | Test field name | Test field description |

@ionic7_failure
Scenario: Add comments & Delete comments (database)
# Create database entry and comment as a teacher
Given I entered the data activity "Data" on course "Course 1" as "teacher1" in the app
Expand Down Expand Up @@ -64,6 +65,7 @@ Feature: Test basic usage of comments in app
When I press the back button in the app
Then I should find "Comments (1)" in the app

@ionic7_failure
Scenario: Add comments offline & Delete comments offline & Sync comments (database)
Given I entered the data activity "Data" on course "Course 1" as "teacher1" in the app
And I press "Add entries" in the app
Expand Down Expand Up @@ -150,6 +152,7 @@ Feature: Test basic usage of comments in app
When I press the back button in the app
And I should find "Comments (1)" in the app

@ionic7_failure
Scenario: Add comments offline & Delete comments offline & Sync comments (glossary)
Given I entered the glossary activity "Test glossary" on course "Course 1" as "teacher1" in the app
And I press "Add a new entry" in the app
Expand Down Expand Up @@ -228,6 +231,7 @@ Feature: Test basic usage of comments in app
When I press the back button in the app
Then I should find "Comments (0)" in the app

@ionic7_failure
Scenario: Add comments offline & Delete comments offline & Sync comments (blogs)
# Create blog as a teacher
Given the following "core_blog > entries" exist:
Expand Down
1 change: 1 addition & 0 deletions src/core/features/course/tests/behat/basic_usage.feature
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ Feature: Test basic usage of one course in app
And I click on "Move right" "link" in the "assignment" activity
And I log out

@ionic7_failure
Scenario: View course contents
When I entered the course "Course 1" as "student1" in the app
Then the header should be "Course 1" in the app
Expand Down
2 changes: 1 addition & 1 deletion src/core/features/login/pages/site/site.html
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ <h1>{{ 'core.login.connecttomoodle' | translate }}</h1>
<ng-container *ngIf="siteSelector !== 'url'">
<ion-item lines="inset">
<ion-input name="url" placeholder="{{ 'core.login.siteaddressplaceholder' | translate }}" formControlName="siteUrl"
[core-auto-focus]="showKeyboard && !showScanQR" (ionChange)="searchSite($event, siteForm.value.siteUrl)"
[core-auto-focus]="showKeyboard && !showScanQR" (ionInput)="searchSite($event, siteForm.value.siteUrl)"
labelPlacement="stacked" [label]="'core.login.siteaddress' | translate" [clearInput]="true" />
</ion-item>

Expand Down
1 change: 1 addition & 0 deletions src/core/features/login/tests/behat/basic_usage.feature
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ Feature: Test basic usage of login in app
Then I should not find "Skip" in the app
And I should find "Connect to Moodle" in the app

@ionic7_failure
Scenario: Add a new account in the app & Site name in displayed when adding a new account
When I launch the app
And I set the field "Your site" to "$WWWROOT" in the app
Expand Down
4 changes: 3 additions & 1 deletion src/core/features/login/tests/behat/signup.feature
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ Feature: Test signup in app
And I should find "These are the authentication instructions." in the app
But I should not find "Create new account" in the app

@ionic7_failure
Scenario: Basic signup
When I launch the app

Expand Down Expand Up @@ -79,7 +80,7 @@ Feature: Test signup in app
Then I should find "Spain" in the app
And I should find "[email protected]" in the app

@lms_from3.10
@ionic7_failure @lms_from3.10
Scenario: Check password policy in signup
Given the following config values are set as admin:
| passwordpolicy | 1 |
Expand Down Expand Up @@ -114,6 +115,7 @@ Feature: Test signup in app
And I press "Create my new account" in the app
Then I should find "An email should have been sent to your address" in the app

@ionic7_failure
Scenario: Signup with custom profile fields
# Use default options Yes/No for menu field because it's not possible to add new lines. See MDL-75788.
Given the following "custom profile fields" exist:
Expand Down
2 changes: 1 addition & 1 deletion src/core/features/mainmenu/tests/behat/mainmenu.feature
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ Feature: Main Menu opens the right page
And "Dashboard" "text" should appear before "Site home" "text" in the ".core-tabs-bar" "css_element"
And "Home" "text" should appear before "My courses" "text" in the ".mainmenu-tabs" "css_element"

@lms_from4.0
@ionic7_failure @lms_from4.0
Scenario: Opens My Courses when defaulthomepage is set to My Courses
Given the following config values are set as admin:
| defaulthomepage | 3 |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ Feature: Set a new reminder on activity
| assign | C1 | assign01 | Assignment 01 | ## yesterday ## | ## now +70 minutes ## |
| assign | C1 | assign02 | Assignment 02 | ## yesterday ## | ## 1 January 2050 ## |

@ionic7_failure
Scenario: Add, delete and update reminder on activity
Given I entered the assign activity "Assignment 01" on course "Course 1" as "student1" in the app

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ Feature: Set a new reminder on course
| user | course | role |
| student1 | C1 | student |

@ionic7_failure
Scenario: Add, delete and update reminder on course
Given I entered the course "Course 1" as "student1" in the app
And I press "Course summary" in the app
Expand Down
1 change: 1 addition & 0 deletions src/core/features/user/tests/behat/basic_usage.feature
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ Feature: Test basic usage of user features
When I press "Reconnect" in the app
Then I should find "Acceptance test site" in the app

@ionic7_failure
Scenario: View profile
Given the following "custom profile fields" exist:
| datatype | shortname | name | required | param1 |
Expand Down
1 change: 1 addition & 0 deletions src/tests/behat/navigation_externallinks.feature
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ Feature: It opens external links properly.
| forum | user | name | message |
| Test forum | student1 | Forum topic | See <a href="https://moodle.org/">moodle.org external link</a> |

@ionic7_failure
Scenario: Click an external link
Given I entered the forum activity "Test forum" on course "Course 1" as "student1" in the app
When I press "Forum topic" in the app
Expand Down
1 change: 1 addition & 0 deletions src/tests/behat/navigation_splitview.feature
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ Feature: It navigates properly in pages with a split-view component.
And I should find "User account" in the app
But I should not find "Back" in the app

@ionic7_failure
Scenario: Navigate in grades tab on tablet

# Open user menu
Expand Down

0 comments on commit f100e59

Please sign in to comment.