commit 3cf3667813ff01f6c21cd01e283d71d6f17080eb640831dc6ca9285dc1b7885d Author: Tomáš Chvátal Date: Thu Mar 21 14:36:20 2019 +0000 Accepting request 687311 from home:jayvdb:coala:test-rig - Fix test suite and add bcond test as the tests require internet OBS-URL: https://build.opensuse.org/request/show/687311 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:pytest/python-pytest-check-links?expand=0&rev=1 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..57affb6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.osc diff --git a/pytest_check_links-0.2.0.tar.gz b/pytest_check_links-0.2.0.tar.gz new file mode 100644 index 0000000..f18a16a --- /dev/null +++ b/pytest_check_links-0.2.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4d74c5b9891d549335d8167102da3ec65d2bcdca23558124523820ea6997ae6d +size 6397 diff --git a/python-pytest-check-links.changes b/python-pytest-check-links.changes new file mode 100644 index 0000000..9cd2572 --- /dev/null +++ b/python-pytest-check-links.changes @@ -0,0 +1,9 @@ +------------------------------------------------------------------- +Thu Mar 21 12:42:55 UTC 2019 - John Vandenberg + +- Fix test suite and add bcond test as the tests require internet + +------------------------------------------------------------------- +Fri Apr 20 21:45:05 UTC 2018 - toddrme2178@gmail.com + +- Initial version diff --git a/python-pytest-check-links.spec b/python-pytest-check-links.spec new file mode 100644 index 0000000..adb8aae --- /dev/null +++ b/python-pytest-check-links.spec @@ -0,0 +1,84 @@ +# +# spec file for package python-pytest-check-links +# +# Copyright (c) 2018 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/ +# + + +# Tests natually require internet +%bcond_with test +%{?!python_module:%define python_module() python-%{**} python3-%{**}} +Name: python-pytest-check-links +Version: 0.2.0 +Release: 0 +Summary: Check links in files +License: BSD-3-Clause +Group: Development/Languages/Python +Url: https://github.com/minrk/pytest-check-links +Source: https://files.pythonhosted.org/packages/source/p/pytest-check-links/pytest_check_links-%{version}.tar.gz +BuildRequires: %{python_module devel} +BuildRequires: %{python_module pbr >= 1.9} +BuildRequires: %{python_module setuptools >= 17.1} +BuildRequires: fdupes +BuildRequires: python-rpm-macros +%if %{with test} +BuildRequires: %{python_module html5lib} +BuildRequires: %{python_module jupyter_nbconvert} +BuildRequires: %{python_module jupyter_nbformat} +BuildRequires: %{python_module pytest >= 2.8} +BuildRequires: %{python_module six} +%endif +Requires: python-html5lib +Requires: python-pytest >= 2.8 +Requires: python-six +Recommends: python-jupyter_nbconvert +Recommends: python-jupyter_nbformat +BuildArch: noarch +Requires(post): update-alternatives +Requires(postun): update-alternatives + +%python_subpackages + +%description +A pytest plugin that checks URLs for HTML-containing files. + +%prep +%setup -q -n pytest_check_links-%{version} + +%build +%python_build + +%install +%python_install +%python_clone -a %{buildroot}%{_bindir}/pytest-check-links +%python_expand %fdupes %{buildroot}%{$python_sitelib} + +%if %{with test} +%check +%python_expand PYTHONPATH=%{buildroot}%{$python_sitelib} $python -m pytest --check-links test/linkcheck.ipynb +%endif + +%post +%python_install_alternative pytest-check-links + +%postun +%python_uninstall_alternative pytest-check-links + +%files %{python_files} +%doc AUTHORS ChangeLog README.md +%license LICENSE +%python_alternative %{_bindir}/pytest-check-links +%{python_sitelib}/* + +%changelog