Bug 8676 - QA: devtool: extend oe-selftest testing for devtool upgrade
Summary: QA: devtool: extend oe-selftest testing for devtool upgrade
Status: RESOLVED FIXED
Alias: None
Product: OE-Core
Classification: Build System, Metadata & Runtime
Component: devtools / tool chain (show other bugs)
Version: 5.99
Hardware: All Multiple
: Medium enhancement
Target Milestone: Future
Assignee: Unassigned
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2015-11-11 15:36 UTC by Paul Eggleton
Modified: 2020-01-09 16:43 UTC (History)
7 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: No (bug/feature does not impact docs)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Paul Eggleton 2015-11-11 15:36:13 UTC
The current "devtool upgrade" test in meta/lib/oeqa/selftest/devtool.py only does a basic test that upgrading a recipe with local source files works, which is not a common use case. We need to also test:

1) Upgrading a recipe pointing to a remote tarball (part of this will be verifying that the checksums get updated)

2) Upgrading a git recipe

As part of these We should also validate that only relevant variables in the recipe get modified (and that they are modified appropriately)
Comment 1 Paul Eggleton 2016-04-27 03:50:10 UTC
For 2.1 the existing test was reworked to test upgrading a recipe pointing to a remote file and do more validation, plus an additional test to upgrade a recipe pointing to a git repository. We should look to see if there are any code paths not tested by these current tests and add tests to cover them.
Comment 2 Leonardo Sandoval Gonzalez 2016-04-27 13:42:10 UTC
(In reply to comment #1)
> For 2.1 the existing test was reworked to test upgrading a recipe pointing
> to a remote file and do more validation, plus an additional test to upgrade
> a recipe pointing to a git repository. We should look to see if there are
> any code paths not tested by these current tests and add tests to cover them.

Thanks for the update. I will review latest code and cover it with tests.
Comment 3 Jose Perez C 2017-06-21 15:46:03 UTC
currently the test for devtool upgrade are covering :

- test_devtool_upgrade
- test_devtool_upgrade_git
- test_devtool_finish_upgrade_origlayer
- test_devtool_finish_upgrade_otherlayer

I is there any missing scenario that you identify that need to be tested ?
Comment 4 Paul Eggleton 2017-07-12 12:09:08 UTC
I would like to see what the coverage of the upgrade module (scripts/lib/devtool/upgrade.py) is - Jose is that something you have easily available?
Comment 5 Jose Perez C 2017-07-13 16:04:40 UTC
(In reply to comment #4)
> I would like to see what the coverage of the upgrade module
> (scripts/lib/devtool/upgrade.py) is - Jose is that something you have easily
> available?

Unfortunately coverage option is not working on new framework (Bug 11582), I will do some tests on pyro and get back to you with the results.
Comment 6 Jose Perez C 2017-07-13 16:05:19 UTC
(In reply to comment #5)
> (In reply to comment #4)
> > I would like to see what the coverage of the upgrade module
> > (scripts/lib/devtool/upgrade.py) is - Jose is that something you have easily
> > available?
> 
> Unfortunately coverage option is not working on new framework (Bug 11582), I
> will do some tests on pyro and get back to you with the results.

Unfortunately coverage option is not working on new framework (Bug 11582), I will do some tests on pyro and get back to you with the results.
Comment 7 Jose Perez C 2017-07-13 21:07:03 UTC
(In reply to comment #6)
> (In reply to comment #5)
> > (In reply to comment #4)
> > > I would like to see what the coverage of the upgrade module
> > > (scripts/lib/devtool/upgrade.py) is - Jose is that something you have easily
> > > available?
> > 
> > Unfortunately coverage option is not working on new framework (Bug 11582), I
> > will do some tests on pyro and get back to you with the results.
> 
> Unfortunately coverage option is not working on new framework (Bug 11582), I
> will do some tests on pyro and get back to you with the results.

A Bug 11786 was opened due coverage is not working properly on pyro, util that is resolved I will not be able to check what is the current coverage.
Comment 8 Jose Perez C 2017-08-30 15:49:38 UTC
Moved to 2.5 due resources constraint
Comment 9 Armin Kuster 2019-12-22 19:22:03 UTC
this still seems reasonable.
Comment 10 Richard Purdie 2020-01-09 16:43:59 UTC
devtool upgrade tests were added. The remaining question here was about code coverage. I don't believe we ever figured out correct tools for code coverage of that they are practical with the system so closing the original issue a resolved. If anyone identifies areas needing further testing we will add them.