diff options
| author | Alassane Yattara <alassane.yattara@savoirfairelinux.com> | 2023-11-21 14:49:17 +0100 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2023-11-23 12:06:06 +0000 |
| commit | f002040d7779965f8b426c4023dd658ae71ecab2 (patch) | |
| tree | f784812ff8fbd83faa4849419d1eca612eec177b /bitbake | |
| parent | 4ff7c528dd0e45a0474e3b6a391ea408ed30f23c (diff) | |
| download | poky-f002040d7779965f8b426c4023dd658ae71ecab2.tar.gz | |
bitbake: toaster/tests: Add UI TestCase - Test edit project name on project page
Test edit project name:
- Click on "Edit" icon button
- Change project name
- Click on "Save" button
- Check project name is changed
(Bitbake rev: 0bd0bbf8df2a1043d5c768a70e4c4fabd5195227)
Signed-off-by: Alassane Yattara <alassane.yattara@savoirfairelinux.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake')
| -rw-r--r-- | bitbake/lib/toaster/tests/functional/test_project_page.py | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/bitbake/lib/toaster/tests/functional/test_project_page.py b/bitbake/lib/toaster/tests/functional/test_project_page.py index f77437f0af..a83a994ba8 100644 --- a/bitbake/lib/toaster/tests/functional/test_project_page.py +++ b/bitbake/lib/toaster/tests/functional/test_project_page.py | |||
| @@ -140,3 +140,30 @@ class TestProjectPage(SeleniumFunctionalTestCase): | |||
| 140 | self.assertTrue( | 140 | self.assertTrue( |
| 141 | '/toastergui/newproject/' in str(self.driver.current_url) | 141 | '/toastergui/newproject/' in str(self.driver.current_url) |
| 142 | ) | 142 | ) |
| 143 | |||
| 144 | def test_edit_project_name(self): | ||
| 145 | """ Test edit project name: | ||
| 146 | - Click on "Edit" icon button | ||
| 147 | - Change project name | ||
| 148 | - Click on "Save" button | ||
| 149 | - Check project name is changed | ||
| 150 | """ | ||
| 151 | # navigate to the project page | ||
| 152 | url = reverse("project", args=(1,)) | ||
| 153 | self.get(url) | ||
| 154 | |||
| 155 | # click on "Edit" icon button | ||
| 156 | self.wait_until_visible('#project-name-container') | ||
| 157 | edit_button = self.find('#project-change-form-toggle') | ||
| 158 | edit_button.click() | ||
| 159 | project_name_input = self.find('#project-name-change-input') | ||
| 160 | self.assertTrue(project_name_input.is_displayed()) | ||
| 161 | project_name_input.clear() | ||
| 162 | project_name_input.send_keys('New Name') | ||
| 163 | self.find('#project-name-change-btn').click() | ||
| 164 | |||
| 165 | # check project name is changed | ||
| 166 | self.wait_until_visible('#project-name-container') | ||
| 167 | self.assertTrue( | ||
| 168 | 'New Name' in str(self.find('#project-name-container').text) | ||
| 169 | ) | ||
