|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
From ca55eafbf7df19ef8726ea2086477efd11308d2b Mon Sep 17 00:00:00 2001
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
From: Alberto Fanjul Alonso <albertofanjul@gmail.com>
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
Date: Tue, 28 Apr 2015 15:44:23 +0200
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
Subject: [PATCH] sysv-generator test: Fix assertion
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
(cherry picked from commit 230f04856647fcfb07d5658f4b8c1cb3557fa0d8)
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
---
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
test/sysv-generator-test.py | 4 ++--
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
diff --git a/test/sysv-generator-test.py b/test/sysv-generator-test.py
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
index 09f5c01762..509899e0a5 100644
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
--- a/test/sysv-generator-test.py
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
+++ b/test/sysv-generator-test.py
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
@@ -323,7 +323,7 @@ class SysvGeneratorTest(unittest.TestCase):
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
self.add_sysv('foo.sh', {'Provides': 'foo bar'})
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
err, results = self.run_generator()
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
# ensure we don't try to create a symlink to itself
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
- self.assertNotIn(err, 'itself')
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
+ self.assertNotIn('itself', err)
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
self.assertEqual(list(results), ['foo.service'])
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
self.assertEqual(results['foo.service'].get('Unit', 'Description'),
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
'LSB: test foo service')
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
@@ -361,7 +361,7 @@ class SysvGeneratorTest(unittest.TestCase):
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
['foo.bak.service', 'foo.old.service', 'foo.service'])
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
# ensure we don't try to create a symlink to itself
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
- self.assertNotIn(err, 'itself')
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
+ self.assertNotIn('itself', err)
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
self.assert_enabled('foo.service', [2, 3, 4, 5])
|
|
Zbigniew Jędrzejewski-Szmek |
a48f80 |
self.assert_enabled('foo.bak.service', [])
|