Message ID | 20231129225340.477401-6-alassane.yattara@savoirfairelinux.com |
---|---|
State | New |
Headers | show |
Series | [1/9] toaster/tests: Update methods wait_until_~ to skip using time.sleep | expand |
On Wed, 2023-11-29 at 23:53 +0100, Alassane Yattara wrote: > Test distros page > - Check if title "Compatible distros" is displayed > - Check search input > - Check "Add layer" button works > - Check distro table feature(show/hide column, pagination) > > Signed-off-by: Alassane Yattara <alassane.yattara@savoirfairelinux.com> > --- > .../tests/functional/test_project_page.py | 51 +++++++++++++++++++ > 1 file changed, 51 insertions(+) I put these into testing but we're seeing failures, including in some of the new tests such as the one in this patch: https://autobuilder.yoctoproject.org/typhoon/#/builders/161/builds/12/steps/11/logs/stdio Cheers, Richard
Hello Richard, Yes, some tests do fail when we run all the test suites together, we are working to resolve this issue: Here are some bugs that we know cause errors/failures: - Testcases fails when they are run out sequence, mainly testcases from tests/functional/ - Build need some fix to work with pytest - Better handle delay between driver actions instead of using time.sleep. All test suites should pass once the above bugs have been fixed. Next actions: 1 - Can you merge these patches, w'll send new patches that fix the above mentioned issues ? Or, 2 - Update current patches to fix above mentioned bugs and re-send patches. Thanks Alassane ----- Mail original ----- De: "Richard Purdie" <richard.purdie@linuxfoundation.org> À: "Alassane Yattara" <alassane.yattara@savoirfairelinux.com>, "toaster" <toaster@lists.yoctoproject.org> Envoyé: Jeudi 30 Novembre 2023 18:28:53 Objet: Re: [Toaster] [PATCH 6/9] toaster/test: Added distro page TestCase On Wed, 2023-11-29 at 23:53 +0100, Alassane Yattara wrote: > Test distros page > - Check if title "Compatible distros" is displayed > - Check search input > - Check "Add layer" button works > - Check distro table feature(show/hide column, pagination) > > Signed-off-by: Alassane Yattara <alassane.yattara@savoirfairelinux.com> > --- > .../tests/functional/test_project_page.py | 51 +++++++++++++++++++ > 1 file changed, 51 insertions(+) I put these into testing but we're seeing failures, including in some of the new tests such as the one in this patch: https://autobuilder.yoctoproject.org/typhoon/#/builders/161/builds/12/steps/11/logs/stdio Cheers, Richard -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#6035): https://lists.yoctoproject.org/g/toaster/message/6035 Mute This Topic: https://lists.yoctoproject.org/mt/102882948/7896845 Group Owner: toaster+owner@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/toaster/unsub [alassane.yattara@savoirfairelinux.com] -=-=-=-=-=-=-=-=-=-=-=-
Hi Alassane, On Thu, 2023-11-30 at 13:29 -0500, Alassane Yattara wrote: > Yes, some tests do fail when we run all the test suites together, we are working to resolve this issue: > Here are some bugs that we know cause errors/failures: > > - Testcases fails when they are run out sequence, mainly testcases from tests/functional/ > - Build need some fix to work with pytest > - Better handle delay between driver actions instead of using time.sleep. > > All test suites should pass once the above bugs have been fixed. > > Next actions: > 1 - Can you merge these patches, w'll send new patches that fix the above mentioned issues ? Or, > 2 - Update current patches to fix above mentioned bugs and re-send patches. I think I will merge them and we can continue to work on things. With the fix from Alexander it does look like we've improved on some of the errors. Cheers, Richard
Richard, All right, once done w'll send fixes as new patches serie. Thanks Alassane ----- Mail original ----- De: "Richard Purdie" <richard.purdie@linuxfoundation.org> À: "Alassane Yattara" <alassane.yattara@savoirfairelinux.com> Cc: "toaster" <toaster@lists.yoctoproject.org> Envoyé: Jeudi 30 Novembre 2023 23:24:19 Objet: Re: [Toaster] [PATCH 6/9] toaster/test: Added distro page TestCase Hi Alassane, On Thu, 2023-11-30 at 13:29 -0500, Alassane Yattara wrote: > Yes, some tests do fail when we run all the test suites together, we are working to resolve this issue: > Here are some bugs that we know cause errors/failures: > > - Testcases fails when they are run out sequence, mainly testcases from tests/functional/ > - Build need some fix to work with pytest > - Better handle delay between driver actions instead of using time.sleep. > > All test suites should pass once the above bugs have been fixed. > > Next actions: > 1 - Can you merge these patches, w'll send new patches that fix the above mentioned issues ? Or, > 2 - Update current patches to fix above mentioned bugs and re-send patches. I think I will merge them and we can continue to work on things. With the fix from Alexander it does look like we've improved on some of the errors. Cheers, Richard -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#6040): https://lists.yoctoproject.org/g/toaster/message/6040 Mute This Topic: https://lists.yoctoproject.org/mt/102882948/7896845 Group Owner: toaster+owner@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/toaster/unsub [alassane.yattara@savoirfairelinux.com] -=-=-=-=-=-=-=-=-=-=-=-
diff --git a/lib/toaster/tests/functional/test_project_page.py b/lib/toaster/tests/functional/test_project_page.py index 47dec1d9..dd33e802 100644 --- a/lib/toaster/tests/functional/test_project_page.py +++ b/lib/toaster/tests/functional/test_project_page.py @@ -644,3 +644,54 @@ class TestProjectPage(SeleniumFunctionalTestCase): self._navigate_to_config_nav('layerstable', 6) # check show rows(pagination) self._mixin_test_table_show_rows(table_selector='layerstable') + + def test_distro_page(self): + """ Test distros page + - Check if title "Compatible distros" is displayed + - Check search input + - Check "Add layer" button works + - Check distro table feature(show/hide column, pagination) + """ + self._navigate_to_config_nav('distrostable', 7) + # check title "Compatible distros" is displayed + self.assertTrue("Compatible Distros" in self.get_page_source()) + # Test search input + input_text='poky-altcfg' + self._mixin_test_table_search_input( + input_selector='search-input-distrostable', + input_text=input_text, + searchBtn_selector='search-submit-distrostable', + table_selector='distrostable' + ) + # check "Add distro" button works + rows = self.find_all('#distrostable tbody tr') + distro_to_add = rows[0] + add_btn = distro_to_add.find_element( + By.XPATH, + '//td[@class="add-del-layers"]' + ) + add_btn.click() + self.wait_until_visible('#change-notification', poll=2) + change_notification = self.find('#change-notification') + self.assertTrue( + f'You have changed the distro to: {input_text}' in change_notification.text + ) + # check distro table feature(show/hide column, pagination) + self._navigate_to_config_nav('distrostable', 7) + column_list = [ + 'description', + 'templatefile', + 'layer_version__get_vcs_reference', + 'layer_version__layer__name', + ] + self._mixin_test_table_edit_column( + 'distrostable', + 'edit-columns-button', + [f'checkbox-{column}' for column in column_list] + ) + self._navigate_to_config_nav('distrostable', 7) + # check show rows(pagination) + self._mixin_test_table_show_rows( + table_selector='distrostable', + to_skip=[150] + )
Test distros page - Check if title "Compatible distros" is displayed - Check search input - Check "Add layer" button works - Check distro table feature(show/hide column, pagination) Signed-off-by: Alassane Yattara <alassane.yattara@savoirfairelinux.com> --- .../tests/functional/test_project_page.py | 51 +++++++++++++++++++ 1 file changed, 51 insertions(+)