more test coverage

pull/1394/head
Chris Caron 2025-08-17 12:37:59 -04:00
parent 58e59370fe
commit 9ba579e813
1 changed files with 48 additions and 3 deletions

View File

@ -181,7 +181,43 @@ apprise_url_tests = (
},
},
),
# Test blocks mode
(
(
"slack://username@xoxb-1234-1234-abc124/#nuxref?footer=yes"
"&timestamp=yes"),
{
"instance": NotifySlack,
"requests_response_text": {
"ok": True,
"message": "",
},
},
),
(
(
"slack://username@xoxb-1234-1234-abc124/#nuxref?footer=yes"
"&timestamp=no"),
{
"instance": NotifySlack,
"requests_response_text": {
"ok": True,
"message": "",
},
},
),
(
(
"slack://username@xoxb-1234-1234-abc124/#nuxref?footer=yes"
"&timestamp=no"),
{
"instance": NotifySlack,
"requests_response_text": {
"ok": True,
"message": "",
},
},
),
# Test blocks mode with timestamp variation
(
(
"slack://?token=T1JJ3T3L2/A1BRTD4JD/TIiajkdnlazkcOXrIdevi7FQ/"
@ -189,7 +225,7 @@ apprise_url_tests = (
),
{"instance": NotifySlack, "requests_response_text": "ok"},
),
# Test blocks mode with timestamp
# Test blocks mode with another timestamp
(
(
"slack://?token=T1JJ3T3L2/A1BRTD4JD/TIiajkdnlazkcOXrIdevi7FQ/"
@ -197,10 +233,19 @@ apprise_url_tests = (
),
{"instance": NotifySlack, "requests_response_text": "ok"},
),
# footer being disabled means timestamp isn't shown
(
(
"slack://?token=T1JJ3T3L2/A1BRTD4JD/TIiajkdnlazkcOXrIdevi7FQ/"
"&to=#chan&blocks=yes&footer=no"
"&to=#chan&blocks=yes&footer=no&timestamp=yes"
),
{"instance": NotifySlack, "requests_response_text": "ok"},
),
# footer and timestamp disabled
(
(
"slack://?token=T1JJ3T3L2/A1BRTD4JD/TIiajkdnlazkcOXrIdevi7FQ/"
"&to=#chan&blocks=yes&footer=no&timestamp=no"
),
{"instance": NotifySlack, "requests_response_text": "ok"},
),