mirror of
https://github.com/caronc/apprise-api.git
synced 2024-12-12 09:50:50 +01:00
updated to work with Apprise v1.8.1
This commit is contained in:
parent
4fbbd8ba65
commit
e50b2dbad9
@ -65,7 +65,7 @@ class StatefulNotifyTests(SimpleTestCase):
|
||||
"""
|
||||
|
||||
# our key to use
|
||||
key = 'test_stateful'
|
||||
key = 'test_stateful_01'
|
||||
|
||||
request = Mock()
|
||||
request.content = b'ok'
|
||||
@ -77,13 +77,11 @@ class StatefulNotifyTests(SimpleTestCase):
|
||||
|
||||
# Preare our list of URLs we want to save
|
||||
urls = [
|
||||
'devops=slack://TokenA/TokenB/TokenC',
|
||||
'pushbullet=pbul://tokendetails',
|
||||
'general,json=json://hostname',
|
||||
]
|
||||
|
||||
# Monkey Patch
|
||||
N_MGR['slack'].enabled = True
|
||||
N_MGR['pbul'].enabled = True
|
||||
N_MGR['json'].enabled = True
|
||||
|
||||
@ -105,7 +103,7 @@ class StatefulNotifyTests(SimpleTestCase):
|
||||
assert response.status_code == 200
|
||||
|
||||
entries = re.split(r'[\r*\n]+', response.content.decode('utf-8'))
|
||||
assert len(entries) == 3
|
||||
assert len(entries) == 2
|
||||
|
||||
form_data = {
|
||||
'body': '## test notification',
|
||||
@ -195,6 +193,7 @@ class StatefulNotifyTests(SimpleTestCase):
|
||||
|
||||
# Now we do a similar approach as the above except we remove the
|
||||
# configuration from under the application
|
||||
key = 'test_stateful_02'
|
||||
for _ in range(10):
|
||||
# No content saved to the location yet
|
||||
response = self.client.post('/get/{}'.format(key))
|
||||
@ -211,7 +210,7 @@ class StatefulNotifyTests(SimpleTestCase):
|
||||
assert response.status_code == 200
|
||||
|
||||
entries = re.split(r'[\r*\n]+', response.content.decode('utf-8'))
|
||||
assert len(entries) == 3
|
||||
assert len(entries) == 2
|
||||
|
||||
form_data = {
|
||||
'body': '## test notification',
|
||||
@ -306,7 +305,7 @@ class StatefulNotifyTests(SimpleTestCase):
|
||||
'body': '## test notification',
|
||||
'format': apprise.NotifyFormat.MARKDOWN,
|
||||
# Comma (OR)
|
||||
'tag': 'general, devops',
|
||||
'tag': 'pushbullet, json',
|
||||
}
|
||||
|
||||
form = NotifyForm(data=form_data)
|
||||
|
@ -10,7 +10,7 @@
|
||||
# apprise @ git+https://github.com/caronc/apprise@custom-tag-or-version
|
||||
|
||||
## 3. The below grabs our stable version (generally the best choice):
|
||||
apprise == 1.8.0
|
||||
apprise == 1.8.1
|
||||
|
||||
## Apprise API Minimum Requirements
|
||||
django
|
||||
|
Loading…
Reference in New Issue
Block a user