| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We want external plugins to be able to make use of the core testing utils.
This commit exposes the basic utilities which are currently in use in
bst-external plugins. If necessary, more utilities could be exposed in the
future.
Moves the following files from tests/testutils/ to
buildstream/plugintestingutils/:
o runcli.py
o integration.py
As part of this, this commit makes the following changes to runcli.py
and integration.py:
o runcli.py: Fix linting errors
o runcli.py: Add user facing documentation
o Integration.py: Add user facing documentation
|
|
|
|
|
| |
Instead of a single target, we can always provide a single target
in a list.
|
|
|
|
|
| |
`remove_artifact_from_cache` used a hard-coded path to remove
artifacts, which wasn't sufficient for integration tests.
|
|
|
|
|
|
|
|
|
| |
With get_element_state(), you need to invoke BuildStream once
for every element state you want to observe in a pipeline.
The new get_element_states() reports a dictionary with
the element state hashed by element name and is better to use
if you have more than one element to observe the state of.
|
|
|
|
|
|
|
|
| |
To ensure we can run integration tests in parallel, use a tempdir
for the artifact cache of each separate integration test run.
This makes it possible to run multiple full test runs including
integration tests in parallel under detox.
|
|
|
|
|
| |
Added a function to report the list of elements which appeared in
a given queue in the order of their first appearance.
|
|
|
|
|
| |
Treat None values in the passed dictionary as keys to be removed
from the environment, this was already happening at restoration time.
|
|
|
|
| |
Fixes issue #740
|
|
|
|
|
|
|
|
| |
In order to test things which write tarballs to stdout correctly,
we need to capture the binary output cleanly. This ensures we're not
potentially mismatching encodings in and out.
Signed-off-by: Daniel Silverstone <daniel.silverstone@codethink.co.uk>
|
|
|
|
|
|
|
|
| |
Pulled/Pushed messages will no longer be produced from within
element.py, instead they will be produced during CasCache push() and
pull() appropriately.
Message consistency has also been improved.
|
|
|
|
|
| |
Note: This modifies the docker containers used for testing to supply the
pytest-timeout package.
|
| |
|
| |
|
|
|
|
| |
This is in preparation for moving away from summary files.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
And adjust all surrounding sources for changed symbols.
Also, added new LoadErrorReason.UNSUPPORTED_PLUGIN, required
for changes in how the project will report format version errors
for plugins at creation time
This is a part of issue #285
|
|
|
|
|
| |
NOTE: artifact was also made lowercase in the function
get_pushed_elements() in runcli.py
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
o CliIntegration.run() now takes a `project_config` option, this
will be composited on top of the existing, substituted project.conf
o Removing gnomesdk alias from integration tests project.conf
o Using `sysroot` alias instead of `gnome7` alias
o Make base-alpine.bst use the `sysroot` alias now
o Removed `create_project_config()` from shell.py tests, now
use the new built-in feature for this which is cleaner.
|
| |
|
|
|
|
|
|
|
|
| |
properly
When testing a recent patch, I had missed a return of the exit code
in `bst shell` resulting in the CLI exiting with `None`; this patch
makes the fixture more helpful, where previously it just printed `None`
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
Enhanced the error checking Result() methods to always assert that
the CLI actually exited, there are no cases worth testing for where
buildstream would be expected to exit on an unhandled exception.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Before this, we only stored the last exception to have been raised in the main
process, now we additionally provide some Result members allowing tests to
inspect a machine readable error `domain` and `reason` describing why
a task has "failed".
This adds some new APIs to the Result() object for tests:
assert_main_error() - asserts the nature of the main buildstream error
assert_task_error() - asserts the nature of the error from a child task
|
|
|
|
|
| |
We need this now in order to properly test the frontend and
parse logs from stderr or output from stdout.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Pytest defaults to capturing stdout, which has the side effect of making
BuildStream realise it's not outputting to a terminal and disabling its
ANSI colour code output.
If you pass `--capture=no` then BuildStream detects the terminal and the
colour codes are emitted, which breaks all of the tests which match on
specific output from `bst`. Forcefully disable colours to fix that.
|
|
|
|
| |
argument
|
| |
|
|
|
|
| |
Hide all of buildstream's internal exceptions from the API surface.
|
|
|
|
|
|
|
|
| |
This wont take any additional time because if there is
a remote artifact share configured in the pytest suite, it
can only be a locally created one - this makes the push/pull
tests work after recently making downloading of remote refs
optional for the sake of issue #140.
|
|
|
|
| |
This is so that we can use it in other contexts than running tests
|
| |
|
| |
|
| |
|
|
|
|
| |
We want to see them in failed test logs even if they succeeded.
|
| |
|
|
|