| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
| |
The display window scrolling mechanism we were using was failing in one case
and needed in another. After trying various approaches, this one with
window.scrollTo seems to work and fixes the test failures.
(Bitbake rev: f1175778108a559e1dd0d55cb68f42816c86f393)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
The project is switching the way handle our CDN provision of sstate objects,
update the URL accordingly.
(Bitbake rev: 3372524cb961d95993b27fe4a8d794cdb7255e09)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
| |
(Bitbake rev: f06112286ad141f0d5e4ae75a29f83cdd564c2ec)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
| |
After the fixture changes, the tests need to be tweaked unfotunately.
(Bitbake rev: 708abd1a8060684127acc7ce4142f05865005750)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
skipping/exception handling
We really don't want to be skipping a test like this, drop the exception handling
code as in my testing we thankfully no longer seem to be seeing it. If we do again
we need to fix the underlying issue.
(Bitbake rev: b67547f890dc7f347ec05a97cbfb22d3703998cc)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix the exception handling in the cancel builds function.
This involved adding WebDriverException which sometimes occurs but
also correcting the other exception handlers to continue to increment
the timeout to avoid test hangs.
(Bitbake rev: e111a2bd4f7a8a4dc2c63e94e91ac6cacca95af8)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
| |
Most of the tests that click on buttons need the DOM to stablise, including
any running JQuery code before the test can proceed. Add calls to do this
whenever we're about to click on an element.
(Bitbake rev: 0eb206b355248e2a874a62baec30025652f2a5a8)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
wait_until_element_clickable before click calls
Switch the clickable() calls to use the new element_clickable() function
which accepts a finder labmda function. This means if the element doesn't
yet exist, the code can rebuild the query and try again once a small
amount of time has elapsed.
There were a ton of timing related races around these element interactions
and this seemed to be the most robust way to address the issues.
The change also makes some of the elements slightly more specific so
the code can work effectively.
(Bitbake rev: 38643aadbb5a960004b886cf7709beaf2fc96652)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
| |
If the element never exists, the timeout is never incremented and the test
hangs indefinitely. Fix the exception handling to avoid that and allow
the timeout to happen.
(Bitbake rev: 9eabe923d457bbce65227da4cd71c275c32108e6)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixes for the browser tests which:
* Add/improve waiting for specific elements
* Waiting for elements to be interactable, not just visible
* Hiding notification windows
* Using more specific asserts to obtain improved error messages
(Bitbake rev: 0c3f9bc2b9516d2af391f2e081280eb7fa62a05e)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
| |
Add a variant of the clickable function that accepts an element parameter.
(Bitbake rev: a34b2451a0e3baaf3b2fd2eb351847ff6a5ee033)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
exception handling
Our own Wait() class allows exception handling which this form of wrapper
does not. Switch the code to use our Wait() class to allow retrying upon
encountering those exceptions (such as an element not being present yet).
The displayed and visible test is what Selenium would be doing internally,
there is no JS reprensetation of clickable directly.
(Bitbake rev: 8266a01b750b3758badeee8fb3a1acfa72c17a93)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
wait_until_build_cancelled
The code modifying the build object requires direct database access
which is potentially problematic. It was being run on a database which
was being reset after changes anyway so the code effectively did nothing.
Remove it as it is unneeded.
(Bitbake rev: 2e3fa624eb3972aef91d877337479eeb0f3dd365)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Drop the remaining poll parameters from the helpers code along
with the remaining sleep call since the tests no longer depend
on this.
This has the nice benefit of significantly speeding up the toaster
test runs (45 minutes down to 12 minutes overall).
If a parameter is needed, it should be the timeout, not the polling
frequency.
(Bitbake rev: 6de912e4f278ffd694fb2258482081dc3bc61c7a)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
drop polling
Drop the poll parameters and make the waits much more specific for
the requirements of the tests. This includes looping waiting for
a list of layer elements as that code was previously particularly
fragile.
(Bitbake rev: cf6b8e8aa5484110a41377ba42b3fdd9d6efd877)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
library create_project function
Switch this test module to use the common project creation code which contains
race fixes. That code requires the database access wrapper be dropped and
we no longer have ordering constraints.
There is one test that does require database access. Move this to a separate class
and allow database access there. Use ordering constraints to allow them to run
after the main code. They depend on the project creation from the other class which
isn't ideal but good enough for now.
(Bitbake rev: fa10ba2a8749415d8f06cfc15c228c6eb7df1bcf)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
In some cases we want to wait until some element is not visible.
Add such a function helper.
(Bitbake rev: cede6519d25112037264550126b109903220b58c)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
These changes:
* Drop the poll parameters
* Add waits where needed or make them more specific
* Add calls to close notification boxes since they can obscure
other page elements
* In one case wait for a "Loading" message to be replaced
(Bitbake rev: 2bde969486a4761fa0e6f9590c9fa08d385666b1)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
| |
elsewhere
The project creation test is well covered in another module so just
drop this one as there isn't any extra value added here.
(Bitbake rev: d26414f191c73fb5330d10d97e240150a3fa1ee8)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
create_project function
Switch this test module to use the common project creation code which contains
race fixes. That code requires the database access wrapper be dropped and
we no longer have ordering constraints.
There are two tests that do require database access. Move these to a separate class
and allow database access there. Use ordering constraints to allow them to run
after the main code. They depend on the project creation from the other class which
isn't ideal but good enough for now.
(Bitbake rev: e441bfe98ac41d48692ffbaeec90a9c780337fa4)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
| |
avoid polling
Drop poll calls within the module, adding wait calls for elements of the
page where testing showed it was needed.
(Bitbake rev: 26746eae31f126ff87e678da66dcc976e412c89b)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
| |
selection to a common function
The project page selection code is race prone. Create a common function to resolve
the race issue and use it from all the call sites rather than duplicate code.
(Bitbake rev: f2bd615b97a6ff3944fa9c1d89a0ea996a12943d)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
| |
Drop the remaining poll values and the sleep within the main wait function
as the races this was working around now seem to be resolved with the
preceeding patches.
(Bitbake rev: 91e54cbacc57316a4f2ca766afac81e7f3a54718)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
In my testing I wasn't able to see issues needing the poll parameter in the
browser tests. Drop those.
(Bitbake rev: 3be5e7c78129abf059476416279718156fc666b5)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Rather than hardcoded poll and sleep values, we want an overall long timeout
and to drop all the other 'sleeping' code.
To facilitate this, increase the overall timeout so we can then start to
remove the other values.
(Bitbake rev: 69a479383f9a8cae6600ce51b12b62be3a15ea38)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The tests would race and potentially fail as the elements on the
page being waited for were not specific enough.
Add suitable elements to wait for and drop the remainder of the poll
parameters since these are no longer needed since we no longer need
to sleep for things to appear.
(Bitbake rev: 9db2fd8534610ad8db90a7a696fa7b748b497d15)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
readability
The 'fail' calls are useful for find() failures but not for wrapping existing asserts
where they hide more useful error messages. Rework the code flow to give more readable
error reporting.
(Bitbake rev: 1a7a9af418874d3112aa6f148b30e5a4d3d176f3)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
| |
Switch this test module to use the common project creation code which contains
race fixes. That code requires the database access wrapper be dropped and
we no longer have ordering constraints.
(Bitbake rev: 653233a1c798d71800b41d3321203a48aa0337d8)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
| |
Switch this test module to use the common project creation code which contains
race fixes. That code requires the database access wrapper be dropped and
we no longer have ordering constraints.
(Bitbake rev: f015d96e28d89fd0aef76ff127ebde8613125a66)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
better reuse
Tweak the function name and return the created project ID.
Allow the release_name test to be skipped with a value of None.
Add an extra wait call to ensure the create project button is ready
before clicking it.
(Bitbake rev: d20c6e3c67298c5db33b220a2e4a554e6f2c4418)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
| |
class as helper
The test project creation is needed by mutliple tests. Move it to the
base class as a helper function for reuse.
(Bitbake rev: abe483b98b38e95b4ad42629a67fb5d243c94094)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Mixing database access and access via a running server is fraught with
danger and problems. The "django_db" marker means the transactions are
dropped at the end of the test but the transactions made via the webapi
remain so the database ends up confused at best.
Drop the database accesses and use the server API. This means slightly
abusing the typeahead to get lists of projects in the database.
Add code to delete a project if it already exists. This allows tests
to re-run against an existing database. Deletion is done using the
server API but this means handling CSRF tokens.
Add requests module requirement to requirements file since the project
creation code now uses requests.
(Bitbake rev: 738270c53a08ddc95400de70f3dd8c08b2940182)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
assetTrue is a poor choice for "x in y" since assertIn gives much more
useful output upon failure.
Change such inserts to assertIn or assertEqual to make errors easier
to debug.
(Bitbake rev: dde78e0ff8af872fdc5cdf5354174fc713141102)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
| |
Python 3.9 isn't our minimum version yet, avoid using removeprefix.
(Bitbake rev: 8cb9eb6a4f1be4620fcde347faa5c1fb6d77bf70)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
On faster machines these tests are failing as the tests are running
before the page has rendered. Add appripriate wait calls.
(Bitbake rev: c3a425ac3ccafa7b06b319c6a525773d04a2ddac)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
| |
The WebDriverException can occur if elements are not present in the DOM
yet. Catch and handle this. It is our most frequently occuring failure
in automated testing now.
(Bitbake rev: 006173cbd32116ff1cea59b2c99eead807be39bb)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
THe test fails on faster systems as we need to wait. Fix that and
a typo.
(Bitbake rev: 749b561196b0b1b388051b345fee2efb6ce68ff7)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
| |
Using a hardcoded database ID for a recipe is a bad idea and causes tests
to fail when we change data/versions.
Remove magic numbers.
(Bitbake rev: 6e3a958666ae4821cfa1d43c064a2294e6881638)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Consistently use meta-poky as the test target, instead of a magic number
ID which can vary.
Fix incorrect comments.
Also ensure the viewport is scrolled to the top when changing tabs.
This breaks if other layers are selected like openembedded-core due
to the number of recipes.
(Bitbake rev: 0bcb7b4a8d8e89647aa6179cc61e5eb55d433585)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
| |
"False is not True" is not a helpful error messgae. "XXX not in YYY" is
much more helpful. Tweak the test to give more meaninful failure messages
using assertIn rather than assertTrue.
(Bitbake rev: 6292b5a81ce1f3cf35980d0f669a1b52f3c56695)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
When the fixtures were updated for the styhead release, the test cases
were not updated to match. Fix this.
(Bitbake rev: d40bd9d35fa3850e77a1e349dab2308a54d70d60)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The test_single_layer_page test case consistently fails. It is not obvious why
but if we change the argument in the following from 8 to 7 it passes.
url = reverse("layerdetails", args=(TestProjectPage.project_id, 8))
E selenium.common.exceptions.TimeoutException: Message: An element matching "#change-notification" should be visible
=========================== short test summary info ============================
FAILED ../bitbake/lib/toaster/tests/functional/test_project_page.py::TestProjectPage::test_single_layer_page
(Bitbake rev: c7e12145d8ea641925e3c06ba4f11c2dae66288a)
Signed-off-by: Tim Orling <tim.orling@konsulko.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In line with changes in gen_fixtures.py:
* Add projectscarthgap
- Add Scarthgap to slot 1.
* Move Kirkstone down to slot 4
* Drop projectdunfell
- Drop EOL Dunfell from slot 5
(Bitbake rev: a4ae788f95d8e54713528374a9171c636aa747c5)
Signed-off-by: Tim Orling <tim.orling@konsulko.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Test if some rows are visible in table instead of compare row to row_to_show,
because sometime full avaiblable content did not display
Failed: https://autobuilder.yoctoproject.org/typhoon/#/builders/161/builds/147/steps/12/logs/stdio
(Bitbake rev: 5b0a48265aafa62259c575707c3afa6dd56f8008)
Signed-off-by: Alassane Yattara <alassane.yattara@savoirfairelinux.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
| |
TestLayerDetailsPage::test_edit_layerdetails
Failed: https://autobuilder.yoctoproject.org/typhoon/#/builders/161/builds/143/steps/12/logs/stdio
(Bitbake rev: 187e96eb7393632f28a195f280fa133439bdc0fa)
Signed-off-by: Alassane Yattara <alassane.yattara@savoirfairelinux.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
Failed: https://autobuilder.yoctoproject.org/typhoon/#/builders/161/builds/142
(Bitbake rev: 0ee5f4e06476b0ec2f5ea8c9f05d299ddda6312b)
Signed-off-by: Alassane Yattara <alassane.yattara@savoirfairelinux.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
Recurring test failures result from insufficient delays in driver actions.
(Bitbake rev: b0de2a61d14fbf30e338751b285b3bab80192275)
Signed-off-by: Alassane Yattara <alassane.yattara@savoirfairelinux.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
Wait for element visible on create new project page
(Bitbake rev: 664de3f6d3484b94f5d82ec634b512b825553aa9)
Signed-off-by: Alassane Yattara <alassane.yattara@savoirfairelinux.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
| |
Fix "element click intercepted" on TestProjectConfigTab::test_project_config_tab_right_section
(Bitbake rev: c8685c762aa1fab687ff3a0943487675ef720755)
Signed-off-by: Alassane Yattara <alassane.yattara@savoirfairelinux.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
TestProjectConfigTab::test_image_recipe_show_rows
Check some rows are visible in table instead of compare table row to
row_to_show, because recipe image table sometime doesn't display full avaiblable
images
(Bitbake rev: 1e2e5927ef7a8adfd3d0a3be1c75b4aa410d9908)
Signed-off-by: Alassane Yattara <alassane.yattara@savoirfairelinux.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|