summaryrefslogtreecommitdiff
path: root/python-ndjson-testrunner.spec
diff options
context:
space:
mode:
Diffstat (limited to 'python-ndjson-testrunner.spec')
-rw-r--r--python-ndjson-testrunner.spec93
1 files changed, 93 insertions, 0 deletions
diff --git a/python-ndjson-testrunner.spec b/python-ndjson-testrunner.spec
new file mode 100644
index 0000000..0d52531
--- /dev/null
+++ b/python-ndjson-testrunner.spec
@@ -0,0 +1,93 @@
+%global _empty_manifest_terminate_build 0
+Name: python-ndjson-testrunner
+Version: 1.0.0
+Release: 1
+Summary: A test runner that outputs newline delimited JSON results
+License: GPL
+URL: https://github.com/flying-sheep/ndjson-testrunner
+Source0: https://mirrors.nju.edu.cn/pypi/web/packages/fc/62/f960a6d540c7c74d15675185334861458619cc9de74d0e784e371db9104a/ndjson-testrunner-1.0.0.tar.gz
+BuildArch: noarch
+
+
+%description
+A unittest_ ``TestRunner`` that outputs ndjson_. One JSON record per test result::
+ {
+ "type": "success" | "expected_failure" | "failure" | "error" | "unexpected_success" | "skip",
+ "id": "module.TestClass.test_function",
+ "desc": null | "First line of test function docstring",
+ "msg": null | "Exception traceback or reason for skipping"
+ }
+To be used for test result storage or interprocess communication.
+
+%package -n python3-ndjson-testrunner
+Summary: A test runner that outputs newline delimited JSON results
+Provides: python-ndjson-testrunner
+BuildRequires: python3-devel
+BuildRequires: python3-setuptools
+BuildRequires: python3-pip
+%description -n python3-ndjson-testrunner
+A unittest_ ``TestRunner`` that outputs ndjson_. One JSON record per test result::
+ {
+ "type": "success" | "expected_failure" | "failure" | "error" | "unexpected_success" | "skip",
+ "id": "module.TestClass.test_function",
+ "desc": null | "First line of test function docstring",
+ "msg": null | "Exception traceback or reason for skipping"
+ }
+To be used for test result storage or interprocess communication.
+
+%package help
+Summary: Development documents and examples for ndjson-testrunner
+Provides: python3-ndjson-testrunner-doc
+%description help
+A unittest_ ``TestRunner`` that outputs ndjson_. One JSON record per test result::
+ {
+ "type": "success" | "expected_failure" | "failure" | "error" | "unexpected_success" | "skip",
+ "id": "module.TestClass.test_function",
+ "desc": null | "First line of test function docstring",
+ "msg": null | "Exception traceback or reason for skipping"
+ }
+To be used for test result storage or interprocess communication.
+
+%prep
+%autosetup -n ndjson-testrunner-1.0.0
+
+%build
+%py3_build
+
+%install
+%py3_install
+install -d -m755 %{buildroot}/%{_pkgdocdir}
+if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi
+if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi
+if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi
+if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi
+pushd %{buildroot}
+if [ -d usr/lib ]; then
+ find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/lib64 ]; then
+ find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/bin ]; then
+ find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/sbin ]; then
+ find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+touch doclist.lst
+if [ -d usr/share/man ]; then
+ find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst
+fi
+popd
+mv %{buildroot}/filelist.lst .
+mv %{buildroot}/doclist.lst .
+
+%files -n python3-ndjson-testrunner -f filelist.lst
+%dir %{python3_sitelib}/*
+
+%files help -f doclist.lst
+%{_docdir}/*
+
+%changelog
+* Thu Mar 09 2023 Python_Bot <Python_Bot@openeuler.org> - 1.0.0-1
+- Package Spec generated