[OE-core] [oeqa][PATCH] lib/oeqa/runtime: add test for gzip

Burton, Ross ross.burton at intel.com
Thu Jan 9 10:14:38 UTC 2014


On 9 January 2014 08:25,  <ting.wang at windriver.com> wrote:
> Function tests:
> 1)gzip compress file
> 2)compressed file integrity check
> 3)zcat compress file
> 4)gzip decompress file

Wouldn't this be better implemented as a ptest for gzip?  The qemu
image tests are more concerned with image-wide functionality that
can't be unit tested independently, but verifying that gzip works can
be.

Also, your test simply verifies that the commands execute, not that
the contents is what you expect: a gzip that produced corrupted
archives wouldn't be detected by this test.

Finally, as I learnt yesterday, the skipUnlessPassed decorator isn't
used to enforce ordering, so test_gzip_fun1_compress only runs after
_create_testfile because it sorts that way alphabetically, not because
of your decorators.  As creating a file isn't a test, just do that in
the test itself.

Ross



More information about the Openembedded-core mailing list