In 1.6 we've made it so that adding and removing INHERIT += "buildhistory" will not change task signatures (other than perhaps do_rootfs or do_populate_sysroot itself). However, because this is dependent on us tweaking variable dependencies to avoid signatures changing, the way the signatures are calculated can change as fixes go in so it's possible we will have regressions in future (as shown demonstrated in bug 5897). Thus, we should have a test to ensure that this continues to work as expected. The test would be as follows: 1) Ensure core-image-minimal (or some other image) is built, without INHERIT += "buildhistory" in the configuration. This doesn't have to be done as part of the test, we just need TMPDIR populated. 2) Add INHERIT += "buildhistory" to the configuration and then bitbake the image again 3) Check if any real tasks other than do_rootfs executed. Alternatively, we could combine this with a test of buildhistory operation when restoring from the sstate cache: 1) Ensure sstate is populated for an image (without INHERIT += "buildhistory" in the configuration), and TMPDIR is deleted. Again, this doesn't have to be done as part of the test, we just need the cache populated. 2) Add INHERIT += "buildhistory" to the configuration and then bitbake the image again 3) Check if any real tasks other than do_rootfs executed. 4) Check if buildhistory for the image and packages that are included in the image was correctly populated.
With the new sstate test infrastructure we can do better than running a build, it can be modelled on lib/oe/qa/selftest/sstatetests.py, take something like test_sstate_sametune_samesigs() but create a version which does "bitbake core-image-sato -S none", then add buildhistory, do "bitbake core-image-sato -S none" again, then check that no new sigatures appears apart from do_rootfs/do_build.
Patch sent to ML: http://lists.openembedded.org/pipermail/openembedded-core/2015-December/114156.html
As of 4c35473a186569daf1685dc3190972299070a661 patch merged into master.