File python3-entrypoints.spec of Package python3-entrypoints

#
# spec file for package python3-entrypoints
#
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#


Name:           python3-entrypoints
Version:        0.2.2
Release:        0
Summary:        Discover and load entry points from installed packages
License:        MIT
Group:          Development/Languages/Python
Url:            https://github.com/takluyver/entrypoints
Source0:        https://github.com/takluyver/entrypoints/archive/%{version}.tar.gz
BuildRequires:  python3
BuildRequires:  python3-pytest
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildArch:      noarch

%description
Entry points are a way for Python packages to advertise objects with
some common interface. The most common examples are console_scripts
entry points, which define shell commands by identifying a Python
function to run.

Groups of entry points, such as console_scripts, point to objects with
similar interfaces. An application might use a group to find its
plugins, or multiple groups if it has different kinds of plugins.

%prep
%setup0 -q -n entrypoints-%{version}

%build
# We don't do anything here

%install
mkdir -p %{buildroot}%{python3_sitelib}
cp -r entrypoints.py %{buildroot}%{python3_sitelib}
%py3_compile %{buildroot}%{python3_sitelib}

%check
pushd tests
PYTHONPATH=%{buildroot}%{python3_sitelib} python3 test_entrypoints.py
popd

%files
%defattr(-,root,root,-)
%doc LICENSE
%{python3_sitelib}/*

%changelog
openSUSE Build Service is sponsored by