Browse Source

Merge pull request #5 from gnuoy/add-setup-tools

Add setup tools
changes/13/749213/1
Alex Kavanagh 2 years ago committed by GitHub
parent
commit
ea51b43ec2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 0
      ops_openstack/__init__.py
  2. 0
      ops_openstack/adapters.py
  3. 0
      ops_openstack/core.py
  4. 18
      setup.cfg
  5. 38
      setup.py
  6. 6
      unit_tests/test_ops_openstack.py

0
ops_openstack/__init__.py

0
adapters.py → ops_openstack/adapters.py

0
ops_openstack.py → ops_openstack/core.py

18
setup.cfg

@ -0,0 +1,18 @@
[metadata]
name = ops_openstack
summary = Common Library for Openstack charms using Ops framework.
version = 0.0.1.dev1
description-file =
README.rst
author = OpenStack Charmers
author-email = openstack-charmers@lists.ubuntu.com
url = https://github.com/openstack-charmers/ops-openstack
classifier =
Development Status :: 2 - Pre-Alpha
Intended Audience :: Developers
Topic :: System
Topic :: System :: Installation/Setup
opic :: System :: Software Distribution
Programming Language :: Python :: 3
Programming Language :: Python :: 3.5
License :: OSI Approved :: Apache Software License

38
setup.py

@ -0,0 +1,38 @@
# -*- coding: utf-8 -*-
# Copyright 2020 Canonical Ltd.
#
# 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.
"""Module used to setup the interface_ceph_client framework."""
from __future__ import print_function
from setuptools import setup, find_packages
version = "0.0.1.dev1"
install_require = [
'charmhelpers',
'ops',
]
tests_require = [
'tox >= 2.3.1',
]
setup(
license='Apache-2.0: http://www.apache.org/licenses/LICENSE-2.0',
packages=find_packages(exclude=["unit_tests"]),
zip_safe=False,
install_requires=install_require,
)

6
unit_tests/test_ops_openstack.py

@ -26,10 +26,10 @@ from ops.model import (
WaitingStatus,
)
import ops_openstack
import ops_openstack.core
class OpenStackTestAPICharm(ops_openstack.OSBaseCharm):
class OpenStackTestAPICharm(ops_openstack.core.OSBaseCharm):
PACKAGES = ['keystone-common']
REQUIRED_RELATIONS = ['shared-db']
@ -75,7 +75,7 @@ class TestOSBaseCharm(CharmTestCase):
'os_utils']
def setUp(self):
super().setUp(ops_openstack, self.PATCHES)
super().setUp(ops_openstack.core, self.PATCHES)
self.os_utils.manage_payload_services = MagicMock()
self.harness = Harness(
OpenStackTestAPICharm,

Loading…
Cancel
Save