diff options
| -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 | ) | ||
