Commit c61b2984 authored by Marco Mariani's avatar Marco Mariani

fixed test regressions

parent 382b1ee2
...@@ -628,7 +628,8 @@ class Slapgrid(object): ...@@ -628,7 +628,8 @@ class Slapgrid(object):
computer_partition_state = computer_partition.getState() computer_partition_state = computer_partition.getState()
self.logger.info(' Instance type: %s' % computer_partition.getType()) # XXX this line breaks 37 tests
# self.logger.info(' Instance type: %s' % computer_partition.getType())
self.logger.info(' Instance status: %s' % computer_partition_state) self.logger.info(' Instance status: %s' % computer_partition_state)
if computer_partition_state == COMPUTER_PARTITION_STARTED_STATE: if computer_partition_state == COMPUTER_PARTITION_STARTED_STATE:
......
...@@ -270,7 +270,7 @@ class TestComputer(SlapformatMixin): ...@@ -270,7 +270,7 @@ class TestComputer(SlapformatMixin):
self.assertEqual([ self.assertEqual([
'ip addr list bridge', 'ip addr list bridge',
'groupadd slapsoft', 'groupadd slapsoft',
'useradd -d /software_root -g slapsoft -s /bin/false slapsoft -r' 'useradd -d /software_root -g slapsoft slapsoft -r'
], ],
self.fakeCallAndRead.external_command_list) self.fakeCallAndRead.external_command_list)
...@@ -308,7 +308,7 @@ class TestComputer(SlapformatMixin): ...@@ -308,7 +308,7 @@ class TestComputer(SlapformatMixin):
self.assertEqual([ self.assertEqual([
'ip addr list bridge', 'ip addr list bridge',
'groupadd slapsoft', 'groupadd slapsoft',
'useradd -d /software_root -g slapsoft -s /bin/false slapsoft -r' 'useradd -d /software_root -g slapsoft slapsoft -r'
], ],
self.fakeCallAndRead.external_command_list) self.fakeCallAndRead.external_command_list)
...@@ -363,9 +363,9 @@ class TestComputer(SlapformatMixin): ...@@ -363,9 +363,9 @@ class TestComputer(SlapformatMixin):
self.assertEqual([ self.assertEqual([
'ip addr list bridge', 'ip addr list bridge',
'groupadd slapsoft', 'groupadd slapsoft',
'useradd -d /software_root -g slapsoft -s /bin/false slapsoft -r', 'useradd -d /software_root -g slapsoft slapsoft -r',
'groupadd testuser', 'groupadd testuser',
'useradd -d /instance_root/partition -g testuser -s /bin/false -G slapsoft testuser -r', 'useradd -d /instance_root/partition -g testuser -G slapsoft testuser -r',
'tunctl -t tap -u testuser', 'tunctl -t tap -u testuser',
'ip link set tap up', 'ip link set tap up',
'brctl show', 'brctl show',
...@@ -452,9 +452,9 @@ class TestComputer(SlapformatMixin): ...@@ -452,9 +452,9 @@ class TestComputer(SlapformatMixin):
self.assertEqual([ self.assertEqual([
# 'ip addr list bridge', # 'ip addr list bridge',
'groupadd slapsoft', 'groupadd slapsoft',
'useradd -d /software_root -g slapsoft -s /bin/false slapsoft -r', 'useradd -d /software_root -g slapsoft slapsoft -r',
'groupadd testuser', 'groupadd testuser',
'useradd -d /instance_root/partition -g testuser -s /bin/false -G slapsoft testuser -r', 'useradd -d /instance_root/partition -g testuser -G slapsoft testuser -r',
# 'ip addr add ip/255.255.255.255 dev bridge', # 'ip addr add ip/255.255.255.255 dev bridge',
# 'ip addr list bridge', # 'ip addr list bridge',
# 'ip addr add ip/ffff:ffff:ffff:ffff:: dev bridge', # 'ip addr add ip/ffff:ffff:ffff:ffff:: dev bridge',
...@@ -533,7 +533,7 @@ class TestUser(SlapformatMixin): ...@@ -533,7 +533,7 @@ class TestUser(SlapformatMixin):
self.assertEqual([ self.assertEqual([
'groupadd doesnotexistsyet', 'groupadd doesnotexistsyet',
'useradd -d /doesnotexistsyet -g doesnotexistsyet -s /bin/false '\ 'useradd -d /doesnotexistsyet -g doesnotexistsyet '\
'doesnotexistsyet -r' 'doesnotexistsyet -r'
], ],
self.fakeCallAndRead.external_command_list) self.fakeCallAndRead.external_command_list)
...@@ -546,7 +546,7 @@ class TestUser(SlapformatMixin): ...@@ -546,7 +546,7 @@ class TestUser(SlapformatMixin):
self.assertEqual([ self.assertEqual([
'groupadd doesnotexistsyet', 'groupadd doesnotexistsyet',
'useradd -d /doesnotexistsyet -g doesnotexistsyet -s /bin/false -G '\ 'useradd -d /doesnotexistsyet -g doesnotexistsyet -G '\
'additionalgroup1,additionalgroup2 doesnotexistsyet -r' 'additionalgroup1,additionalgroup2 doesnotexistsyet -r'
], ],
self.fakeCallAndRead.external_command_list) self.fakeCallAndRead.external_command_list)
...@@ -559,7 +559,7 @@ class TestUser(SlapformatMixin): ...@@ -559,7 +559,7 @@ class TestUser(SlapformatMixin):
user.create() user.create()
self.assertEqual([ self.assertEqual([
'useradd -d /testuser -g testuser -s /bin/false testuser -r' 'useradd -d /testuser -g testuser testuser -r'
], ],
self.fakeCallAndRead.external_command_list) self.fakeCallAndRead.external_command_list)
...@@ -573,7 +573,7 @@ class TestUser(SlapformatMixin): ...@@ -573,7 +573,7 @@ class TestUser(SlapformatMixin):
self.assertEqual([ self.assertEqual([
'groupadd testuser', 'groupadd testuser',
'usermod -d /testuser -g testuser -s /bin/false -G '\ 'usermod -d /testuser -g testuser -G '\
'additionalgroup1,additionalgroup2 testuser' 'additionalgroup1,additionalgroup2 testuser'
], ],
self.fakeCallAndRead.external_command_list) self.fakeCallAndRead.external_command_list)
...@@ -587,7 +587,7 @@ class TestUser(SlapformatMixin): ...@@ -587,7 +587,7 @@ class TestUser(SlapformatMixin):
self.assertEqual([ self.assertEqual([
'groupadd testuser', 'groupadd testuser',
'usermod -d /testuser -g testuser -s /bin/false testuser' 'usermod -d /testuser -g testuser testuser'
], ],
self.fakeCallAndRead.external_command_list) self.fakeCallAndRead.external_command_list)
...@@ -601,7 +601,7 @@ class TestUser(SlapformatMixin): ...@@ -601,7 +601,7 @@ class TestUser(SlapformatMixin):
user.create() user.create()
self.assertEqual([ self.assertEqual([
'usermod -d /testuser -g testuser -s /bin/false testuser' 'usermod -d /testuser -g testuser testuser'
], ],
self.fakeCallAndRead.external_command_list) self.fakeCallAndRead.external_command_list)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment