2023-05-22 13:31:36 +00:00
|
|
|
#
|
2023-05-22 14:56:11 +00:00
|
|
|
# spec file
|
2023-05-22 13:31:36 +00:00
|
|
|
#
|
2024-01-03 10:30:24 +00:00
|
|
|
# Copyright (c) 2024 SUSE LLC
|
2023-05-22 13:31:36 +00:00
|
|
|
#
|
|
|
|
# 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 https://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
|
%define appname vagrant
|
|
|
|
# no tests in OBS, nested virtualization for VirtualBox and internet access for image download from the Vagrant cloud are needed
|
|
|
|
%bcond_with test
|
|
|
|
%if %{with test}
|
|
|
|
%define psuffix -test
|
|
|
|
%else
|
|
|
|
%define psuffix %{nil}
|
|
|
|
%endif
|
|
|
|
Name: python-%{appname}%{psuffix}
|
|
|
|
Version: 1.1.0
|
|
|
|
Release: 0
|
|
|
|
Summary: Python bindings for Vagrant
|
|
|
|
License: MIT
|
|
|
|
Group: Development/Languages/Python
|
|
|
|
URL: https://github.com/pycontribs/python-vagrant
|
2024-01-03 12:57:25 +00:00
|
|
|
Source0: https://github.com/pycontribs/python-vagrant/archive/refs/tags/v%{version}.tar.gz#/%{appname}-%{version}-gh.tar.gz
|
2023-05-22 13:31:36 +00:00
|
|
|
BuildRequires: %{python_module pip}
|
2024-01-03 10:30:24 +00:00
|
|
|
BuildRequires: %{python_module setuptools}
|
2023-05-22 13:31:36 +00:00
|
|
|
BuildRequires: %{python_module wheel}
|
|
|
|
BuildRequires: %{pythons}
|
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: python-rpm-macros
|
|
|
|
Requires: vagrant
|
|
|
|
Provides: python3-python-vagrant
|
|
|
|
BuildArch: noarch
|
|
|
|
%if %{with test}
|
|
|
|
BuildRequires: %{python_module cachetools}
|
|
|
|
BuildRequires: %{python_module chardet}
|
|
|
|
BuildRequires: %{python_module colorama}
|
|
|
|
BuildRequires: %{python_module pyproject-api}
|
|
|
|
BuildRequires: %{python_module pytest}
|
|
|
|
BuildRequires: %{python_module tox}
|
|
|
|
BuildRequires: %{python_module vagrant}
|
|
|
|
BuildRequires: vagrant-vbguest
|
|
|
|
%endif
|
|
|
|
%python_subpackages
|
|
|
|
|
|
|
|
%description
|
|
|
|
Python bindings for interacting with Vagrant virtual machines.
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%autosetup
|
|
|
|
|
|
|
|
%build
|
|
|
|
%if !%{with test}
|
|
|
|
%pyproject_wheel
|
|
|
|
%endif
|
|
|
|
|
|
|
|
%install
|
|
|
|
%if !%{with test}
|
|
|
|
%pyproject_install
|
|
|
|
%python_expand %fdupes %{buildroot}%{$python_sitelib}/%{appname}
|
|
|
|
%endif
|
|
|
|
|
|
|
|
%if %{with test}
|
|
|
|
%check
|
|
|
|
mkdir /tmp/vagrant
|
|
|
|
export VAGRANT_HOME=/tmp/vagrant
|
2023-05-22 14:56:11 +00:00
|
|
|
%pytest tests/test_vagrant.py
|
2023-05-22 13:31:36 +00:00
|
|
|
rm -r /tmp/vagrant
|
|
|
|
%endif
|
|
|
|
|
|
|
|
%if !%{with test}
|
|
|
|
%files %{python_files}
|
|
|
|
%license LICENSE.txt
|
|
|
|
%doc CHANGELOG.md README.md
|
2024-01-03 12:57:25 +00:00
|
|
|
%{python_sitelib}/%{appname}
|
2023-05-22 13:31:36 +00:00
|
|
|
%{python_sitelib}/python_%{appname}-0.0.0.dist-info
|
|
|
|
%endif
|
|
|
|
|
|
|
|
%changelog
|