diff options
author | Tristan Maat <tristan.maat@codethink.co.uk> | 2019-11-18 16:50:57 +0000 |
---|---|---|
committer | Tristan Maat <tristan.maat@codethink.co.uk> | 2019-11-22 11:41:31 +0000 |
commit | 176338b5cc20ac64b2b85bf83f704af7b26f3e6a (patch) | |
tree | 6fba22e388893623fb57841e55cfb6561badb292 /tests/frontend | |
parent | 358727cdd2d3e3e2fccf6731c4a42910e7672202 (diff) | |
download | buildstream-176338b5cc20ac64b2b85bf83f704af7b26f3e6a.tar.gz |
Fix stacktraces during element loading
These were caused by unhandled errors from plugins when calling
`Source.get_consistency()`. This doesn't really solve the problem,
since that interface is still used un-wrapped elsewhere, but it
enables removing `Element.__schedule_tracking()` and fixes a bug.
Ultimately we'd like to remove `Source.get_consistency()`, so this
isn't too long-term of a problem.
Diffstat (limited to 'tests/frontend')
-rw-r--r-- | tests/frontend/fetch.py | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/tests/frontend/fetch.py b/tests/frontend/fetch.py index ff3667707..9258fc7d9 100644 --- a/tests/frontend/fetch.py +++ b/tests/frontend/fetch.py @@ -60,16 +60,8 @@ def test_fetch_consistency_error(cli, datafiles): def test_fetch_consistency_bug(cli, datafiles): project = str(datafiles) - # FIXME: - # - # When a plugin raises an unhandled exception at load - # time, as is the case when running Source.get_consistency() - # for a fetch command, we could report this to the user - # more gracefully as a BUG message. - # result = cli.run(project=project, args=["source", "fetch", "bug.bst"]) - assert result.exc is not None - assert str(result.exc) == "Something went terribly wrong" + result.assert_main_error(ErrorDomain.PLUGIN, "source-bug") @pytest.mark.datafiles(DATA_DIR) |