Browse Source

Add a reproduction test for bug story/2008831

Story: 2008831
Task: 42313

Change-Id: I01b66ad1828cff77adf3aa7490e54be817b8b71b
(cherry picked from commit 9ea3d9b2158e4049e24b80a4a596acb15721634a)
changes/25/787525/2
Balazs Gibizer 3 weeks ago
parent
commit
cb77dc8f8c
1 changed files with 7 additions and 0 deletions
  1. +7
    -0
      placement/tests/functional/cmd/test_status.py

+ 7
- 0
placement/tests/functional/cmd/test_status.py View File

@ -32,6 +32,7 @@ class UpgradeCheckIncompleteConsumersTestCase(
super(UpgradeCheckIncompleteConsumersTestCase, self).setUp()
config = cfg.ConfigOpts()
conf.register_opts(config)
config(args=[], project='placement')
self.checks = status.Checks(config)
def test_check_incomplete_consumers(self):
@ -78,3 +79,9 @@ class UpgradeCheckIncompleteConsumersTestCase(
# Run the check again and it should be successful.
result = self.checks._check_root_provider_ids()
self.assertEqual(upgradecheck.Code.SUCCESS, result.code)
def test_all_registered_check_is_runnable(self):
# this is bug story/2008831
self.assertRaises(cfg.NotInitializedError, self.checks.check)
# after it is fixed we expect that all the checks succeeds
# self.assertEquals(upgradecheck.Code.SUCCESS, self.checks.check())

Loading…
Cancel
Save