commit | 75fa0b093dad62b1eff28a0680a9d134de40dfb2 | [log] [tgz] |
---|---|---|
author | Zuul <zuul@review.openstack.org> | Mon May 07 15:18:38 2018 +0000 |
committer | Gerrit Code Review <review@openstack.org> | Mon May 07 15:18:38 2018 +0000 |
tree | f433c4639fa203f0ce7a01382707a4ec84738164 | |
parent | 34b5503592ae2e94bad656324d656335953c563f [diff] | |
parent | 814a87ca6f48b3ee221843fbc68cb3d7fc2df4a1 [diff] |
Merge "Modify the empty list ensure method"
diff --git a/tempest/cmd/init.py b/tempest/cmd/init.py index 9a85d89..84c8631 100644 --- a/tempest/cmd/init.py +++ b/tempest/cmd/init.py
@@ -136,7 +136,7 @@ if not os.path.isdir(local_dir): LOG.debug('Creating local working dir: %s', local_dir) os.mkdir(local_dir) - elif not os.listdir(local_dir) == []: + elif os.listdir(local_dir): raise OSError("Directory you are trying to initialize already " "exists and is not empty: %s" % local_dir)