2020-06-17 13:09:22 +00:00
|
|
|
#
|
|
|
|
# spec file for package python-django-push-notifications
|
|
|
|
#
|
2024-04-03 03:45:57 +00:00
|
|
|
# Copyright (c) 2024 SUSE LLC
|
2020-06-17 13:09:22 +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/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
2023-11-29 12:16:10 +00:00
|
|
|
%{?sle15_python_module_pythons}
|
2020-06-17 13:09:22 +00:00
|
|
|
Name: python-django-push-notifications
|
2023-11-29 12:16:10 +00:00
|
|
|
Version: 3.0.2
|
2020-06-17 13:09:22 +00:00
|
|
|
Release: 0
|
|
|
|
Summary: Django package to send push notifications to mobile devices
|
|
|
|
License: MIT
|
|
|
|
URL: https://github.com/jazzband/django-push-notifications
|
2024-04-03 03:45:57 +00:00
|
|
|
Source: https://files.pythonhosted.org/packages/source/d/django-push-notifications/django-push-notifications-%{version}.tar.gz
|
2023-01-06 01:51:48 +00:00
|
|
|
Patch0: support-new-apns2.patch
|
2024-04-03 03:45:57 +00:00
|
|
|
BuildRequires: %{python_module setuptools_scm}
|
2020-06-17 13:09:22 +00:00
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: python-rpm-macros
|
|
|
|
Requires: python-Django >= 1.11
|
|
|
|
Requires: python-pywebpush >= 1.3.0
|
|
|
|
Suggests: python-apns2 >= 0.3.0
|
|
|
|
BuildArch: noarch
|
|
|
|
# SECTION test requirements
|
|
|
|
BuildRequires: %{python_module Django >= 1.11}
|
|
|
|
BuildRequires: %{python_module apns2}
|
2021-12-26 14:35:58 +00:00
|
|
|
BuildRequires: %{python_module django-codemod}
|
2022-05-11 10:51:54 +00:00
|
|
|
BuildRequires: %{python_module djangorestframework >= 3.7}
|
|
|
|
BuildRequires: %{python_module pip}
|
|
|
|
BuildRequires: %{python_module pytest-cov}
|
2020-06-17 13:09:22 +00:00
|
|
|
BuildRequires: %{python_module pytest-django}
|
|
|
|
BuildRequires: %{python_module pytest}
|
|
|
|
BuildRequires: %{python_module pywebpush >= 1.3.0}
|
2022-05-11 10:51:54 +00:00
|
|
|
BuildRequires: %{python_module wheel}
|
2020-06-17 13:09:22 +00:00
|
|
|
# /SECTION
|
|
|
|
%python_subpackages
|
|
|
|
|
|
|
|
%description
|
|
|
|
Send push notifications to mobile devices through GCM, APNS or WNS and
|
|
|
|
to WebPush (Chrome, Firefox and Opera) in Django.
|
|
|
|
|
|
|
|
%prep
|
2023-01-06 01:51:48 +00:00
|
|
|
%autosetup -p1 -n django-push-notifications-%{version}
|
2021-12-26 14:35:58 +00:00
|
|
|
djcodemod run --removed-in 4.0 push_notifications/{admin,fields,models}.py
|
2020-06-17 13:09:22 +00:00
|
|
|
|
|
|
|
%build
|
2022-05-11 10:51:54 +00:00
|
|
|
%pyproject_wheel
|
2020-06-17 13:09:22 +00:00
|
|
|
|
|
|
|
%install
|
2022-05-11 10:51:54 +00:00
|
|
|
%pyproject_install
|
2020-06-17 13:09:22 +00:00
|
|
|
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
|
|
|
|
|
|
|
%check
|
|
|
|
export DJANGO_SETTINGS_MODULE=tests.settings
|
2020-08-06 05:50:47 +00:00
|
|
|
export PYTHONPATH="$(pwd)"
|
2020-06-17 13:09:22 +00:00
|
|
|
%pytest
|
|
|
|
|
|
|
|
%files %{python_files}
|
|
|
|
%doc README.rst
|
|
|
|
%license LICENSE
|
2024-04-03 03:45:57 +00:00
|
|
|
%{python_sitelib}/push_notifications
|
|
|
|
%{python_sitelib}/django_push_notifications-%{version}.dist-info
|
2020-06-17 13:09:22 +00:00
|
|
|
|
|
|
|
%changelog
|