Skip to content

Commit

Permalink
[fix] resolve rebase conflicts - pre-commit PR
Browse files Browse the repository at this point in the history
* [pre-commit.ci] pre-commit autoupdate (#669)
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/pre-commit/pre-commit-hooks: v4.3.0 → v4.4.0](pre-commit/pre-commit-hooks@v4.3.0...v4.4.0)
- [github.com/asottile/pyupgrade: v2.37.3 → v3.10.1](asottile/pyupgrade@v2.37.3...v3.10.1)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: jscarlett <[email protected]>
  • Loading branch information
2 people authored and 50-Course committed Oct 3, 2024
1 parent 8a22456 commit 25784b2
Show file tree
Hide file tree
Showing 8 changed files with 9 additions and 7 deletions.
2 changes: 1 addition & 1 deletion push_notifications/conf/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ def _validate_apns_certificate(self, certfile):
"""Validate the APNS certificate at startup."""

try:
with open(certfile, "r") as f:
with open(certfile) as f:
content = f.read()
check_apns_certificate(content)
except Exception as e:
Expand Down
1 change: 0 additions & 1 deletion push_notifications/migrations/0001_initial.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
from django.conf import settings
from django.db import migrations, models

Expand Down
1 change: 0 additions & 1 deletion push_notifications/migrations/0002_auto_20160106_0850.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.9.1 on 2016-01-06 08:50
from django.db import migrations, models

Expand Down
1 change: 0 additions & 1 deletion push_notifications/migrations/0003_wnsdevice.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.9.6 on 2016-06-13 20:46
import django.db.models.deletion
from django.conf import settings
Expand Down
1 change: 0 additions & 1 deletion push_notifications/migrations/0004_fcm.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.9.6 on 2016-06-13 20:46
from django.conf import settings
from django.db import migrations, models
Expand Down
1 change: 0 additions & 1 deletion push_notifications/migrations/0005_applicationid.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
from django.conf import settings
from django.db import migrations, models

Expand Down
1 change: 0 additions & 1 deletion push_notifications/migrations/0006_webpushdevice.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
from django.conf import settings
from django.db import migrations, models

Expand Down
8 changes: 8 additions & 0 deletions tests/test_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -459,9 +459,17 @@ def test_fcm_send_message_with_no_reg_ids(self):
return_value=responses.FCM_SUCCESS_MULTIPLE
) as p:
reg_ids = [obj.registration_id for obj in GCMDevice.objects.all()]
<<<<<<< HEAD
message = dict_to_fcm_message({"message": "Hello World"})
send_bulk_message(reg_ids, message)
p.assert_called_once()
=======
send_bulk_message(reg_ids, {"message": "Hello World"}, "FCM")
p.assert_called_once_with(
["abc", "abc1"], {"message": "Hello World"}, cloud_type="FCM",
application_id=None
)
>>>>>>> 34d6c54 ([pre-commit.ci] pre-commit autoupdate (#669))

def test_can_save_wsn_device(self):
device = GCMDevice.objects.create(registration_id="a valid registration id")
Expand Down

0 comments on commit 25784b2

Please sign in to comment.