Fix gate error
Looks like SQLAlchemy in version 1.2.x checks if the boolean value is None, True, False, 1, or 0. We used a "1" in our test, which does not seem to meet the requirements. In the meantime, if we change it to 1 here, our function section needs to be changed as well. Change-Id: I8df2118fee12fd9dd02caf96a23bc59652efbed7
This commit is contained in:
parent
393c5f8c00
commit
21dcb414e5
@ -212,7 +212,8 @@ def main():
|
|||||||
'packages', help='Packages required by the datastore version that '
|
'packages', help='Packages required by the datastore version that '
|
||||||
'are installed on the guest image.')
|
'are installed on the guest image.')
|
||||||
parser.add_argument(
|
parser.add_argument(
|
||||||
'active', help='Whether the datastore version is active or not. '
|
'active', type=int,
|
||||||
|
help='Whether the datastore version is active or not. '
|
||||||
'Accepted values are 0 and 1.')
|
'Accepted values are 0 and 1.')
|
||||||
|
|
||||||
parser = subparser.add_parser(
|
parser = subparser.add_parser(
|
||||||
|
@ -31,10 +31,10 @@ class TestDatastoreVersion(trove_testtools.TestCase):
|
|||||||
models.update_datastore(name='test_ds', default_version=None)
|
models.update_datastore(name='test_ds', default_version=None)
|
||||||
models.update_datastore_version(
|
models.update_datastore_version(
|
||||||
'test_ds', 'test_vr1', 'mysql',
|
'test_ds', 'test_vr1', 'mysql',
|
||||||
'154b350d-4d86-4214-9067-9c54b230c0da', 'pkg-1', '1')
|
'154b350d-4d86-4214-9067-9c54b230c0da', 'pkg-1', 1)
|
||||||
models.update_datastore_version(
|
models.update_datastore_version(
|
||||||
'test_ds', 'test_vr2', 'mysql',
|
'test_ds', 'test_vr2', 'mysql',
|
||||||
'154b350d-4d86-4214-9067-9c54b230c0da', 'pkg-1', '1')
|
'154b350d-4d86-4214-9067-9c54b230c0da', 'pkg-1', 1)
|
||||||
self.ds = models.Datastore.load('test_ds')
|
self.ds = models.Datastore.load('test_ds')
|
||||||
self.ds_version2 = models.DatastoreVersion.load(self.ds, 'test_vr2')
|
self.ds_version2 = models.DatastoreVersion.load(self.ds, 'test_vr2')
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user