diff options
| author | Armin Kuster <akuster808@gmail.com> | 2020-01-01 08:36:36 -0800 |
|---|---|---|
| committer | Armin Kuster <akuster808@gmail.com> | 2020-01-03 11:54:14 -0800 |
| commit | 6400eba66a328db21d284f4d77e65ee1608cec00 (patch) | |
| tree | 00bddcdeee7f88e33914ccf17c7c3b96c1da311f | |
| parent | 41506052f65a67312119030ec178c8f7f6304dd3 (diff) | |
| download | meta-security-6400eba66a328db21d284f4d77e65ee1608cec00.tar.gz | |
lib/oeqa/runtime: fix clamav test order
Signed-off-by: Armin Kuster <akuster808@gmail.com>
| -rw-r--r-- | lib/oeqa/runtime/cases/clamav.py | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/lib/oeqa/runtime/cases/clamav.py b/lib/oeqa/runtime/cases/clamav.py index 2808df4..cf83937 100644 --- a/lib/oeqa/runtime/cases/clamav.py +++ b/lib/oeqa/runtime/cases/clamav.py | |||
| @@ -48,6 +48,15 @@ class ClamavTest(OERuntimeTestCase): | |||
| 48 | self.assertEqual(status, 0, msg = msg) | 48 | self.assertEqual(status, 0, msg = msg) |
| 49 | 49 | ||
| 50 | @OETestDepends(['clamav.ClamavTest.test_ping_clamav_net']) | 50 | @OETestDepends(['clamav.ClamavTest.test_ping_clamav_net']) |
| 51 | def test_freshclam_check_mirrors(self): | ||
| 52 | status, output = self.target.run('freshclam --list-mirrors') | ||
| 53 | match = re.search('Failures: 0', output) | ||
| 54 | if not match: | ||
| 55 | msg = ('freshclam --list-mirrors: failed. ' | ||
| 56 | 'Status and output:%s and %s' % (status, output)) | ||
| 57 | self.assertEqual(status, 1, msg = msg) | ||
| 58 | |||
| 59 | @OETestDepends(['clamav.ClamavTest.test_freshclam_check_mirrors']) | ||
| 51 | def test_freshclam_download(self): | 60 | def test_freshclam_download(self): |
| 52 | status, output = self.target.run('freshclam --show-progress') | 61 | status, output = self.target.run('freshclam --show-progress') |
| 53 | match = re.search('Database updated', output) | 62 | match = re.search('Database updated', output) |
| @@ -57,12 +66,3 @@ class ClamavTest(OERuntimeTestCase): | |||
| 57 | 'Status and output:%s and %s' % (status, output)) | 66 | 'Status and output:%s and %s' % (status, output)) |
| 58 | self.assertEqual(status, 1, msg = msg) | 67 | self.assertEqual(status, 1, msg = msg) |
| 59 | 68 | ||
| 60 | @OETestDepends(['clamav.ClamavTest.test_ping_clamav_net']) | ||
| 61 | def test_freshclam_check_mirrors(self): | ||
| 62 | status, output = self.target.run('freshclam --list-mirrors') | ||
| 63 | match = re.search('Failures: 0', output) | ||
| 64 | if not match: | ||
| 65 | msg = ('freshclam --list-mirrors: failed. ' | ||
| 66 | 'Status and output:%s and %s' % (status, output)) | ||
| 67 | self.assertEqual(status, 1, msg = msg) | ||
| 68 | |||
