diff --git a/mistralclient/__init__.py b/mistralclient/__init__.py index e69de29b..f8f1a431 100644 --- a/mistralclient/__init__.py +++ b/mistralclient/__init__.py @@ -0,0 +1,19 @@ +# Copyright 2014 Rackspace Hosting +# +# Licensed under the Apache License, Version 2.0 (the "License"); you may +# not use this file except in compliance with the License. You may obtain +# a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +# License for the specific language governing permissions and limitations +# under the License. + +import pbr.version + + +__version__ = pbr.version.VersionInfo( + 'python-mistralclient').version_string() diff --git a/mistralclient/tests/test_cli_executions.py b/mistralclient/tests/test_cli_executions.py index 529bcedb..e99add6f 100644 --- a/mistralclient/tests/test_cli_executions.py +++ b/mistralclient/tests/test_cli_executions.py @@ -21,7 +21,6 @@ import mock from mistralclient.tests import base from mistralclient.commands import executions from mistralclient.api.executions import Execution -from mistralclient import version EXECUTION = Execution(mock, { 'id': '123', @@ -44,7 +43,7 @@ class TestCLIExecutions(base.BaseCommandTest): @mock.patch('mistralclient.api.executions.ExecutionManager.create') def test_create_ctx_file(self, mock): mock.return_value = EXECUTION - path = pkg.resource_filename(version.version_info.package, + path = pkg.resource_filename('mistralclient', 'tests/resources/ctx.json') result = self.call(executions.Create, app_args=['name', 'id', path]) diff --git a/mistralclient/version.py b/mistralclient/version.py deleted file mode 100644 index 1f23e988..00000000 --- a/mistralclient/version.py +++ /dev/null @@ -1,20 +0,0 @@ -# -*- coding: utf-8 -*- -# -# Copyright 2013 - Mirantis, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -from pbr import version - -version_info = version.VersionInfo('mistralclient') -version_string = version_info.version_string