runtime: Add cleanup for logrotate tests
Delete logrotate dir to avoid errors when test are executed more than 1 time on the same target. (From OE-Core rev: 02c98c848163a6837692fe74a91754701a44a6c0) Signed-off-by: Jose Perez Carranza <jose.perez.carranza@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
parent
6e2b26eb22
commit
970b76a728
|
@ -27,3 +27,4 @@ class LogrotateTest(oeRuntimeTest):
|
|||
self.assertEqual(status, 0, msg = "logrotate service could not be reloaded. Status and output: %s and %s" % (status, output))
|
||||
output = self.target.run('ls -la $HOME/logrotate_dir/ | wc -l')[1]
|
||||
self.assertTrue(int(output)>=3, msg = "new logfile could not be created. List of files within log directory: %s" %(self.target.run('ls -la $HOME/logrotate_dir')[1]))
|
||||
self.target.run('rm -rf $HOME/logrotate_dir')
|
||||
|
|
Loading…
Reference in New Issue