Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

integrations/appveyor: Use global time.

Niloth P9e89b65e575d
diff --git a/static/images/integrations/appveyor/001.png b/static/images/integrations/appveyor/001.png
index e54062dfaf8..970425d3cd5 100644
Binary files a/static/images/integrations/appveyor/001.png and b/static/images/integrations/appveyor/001.png differ
diff --git a/zerver/webhooks/appveyor/tests.py b/zerver/webhooks/appveyor/tests.py
index 78c6d8c28f1..d37c150ac6f 100644
--- a/zerver/webhooks/appveyor/tests.py
+++ b/zerver/webhooks/appveyor/tests.py
@@ -14,8 +14,8 @@ class AppveyorHookTests(WebhookTestCase):
expected_message = """
[Build Hubot-DSC-Resource 2.0.59 completed](https://ci.appveyor.com/project/joebloggs/hubot-dsc-resource/build/2.0.59):
* **Commit**: [c06e208b47: Increment version number.](https://github.com/joebloggs/Hubot-DSC-Resource/commit/c06e208b47) by Joe Bloggs
-* **Started**: 9/9/2018 7:04 PM
-* **Finished**: 9/9/2018 7:06 PM
+* **Started**: <time:9/9/2018 7:04 PM>
+* **Finished**: <time:9/9/2018 7:06 PM>
""".strip()
self.check_webhook("appveyor_build_success", expected_topic_name, expected_message)
@@ -28,8 +28,8 @@ class AppveyorHookTests(WebhookTestCase):
expected_message = """
[Build Hubot-DSC-Resource 2.0.59 failed](https://ci.appveyor.com/project/joebloggs/hubot-dsc-resource/build/2.0.59):
* **Commit**: [c06e208b47: Increment version number.](https://github.com/joebloggs/Hubot-DSC-Resource/commit/c06e208b47) by Joe Bloggs
-* **Started**: 9/9/2018 7:04 PM
-* **Finished**: 9/9/2018 7:06 PM
+* **Started**: <time:9/9/2018 7:04 PM>
+* **Finished**: <time:9/9/2018 7:06 PM>
""".strip()
self.check_webhook("appveyor_build_failure", expected_topic_name, expected_message)
diff --git a/zerver/webhooks/appveyor/view.py b/zerver/webhooks/appveyor/view.py
index fab13615715..7188b48604e 100644
--- a/zerver/webhooks/appveyor/view.py
+++ b/zerver/webhooks/appveyor/view.py
@@ -12,8 +12,8 @@ APPVEYOR_TOPIC_TEMPLATE = "{project_name}"
APPVEYOR_MESSAGE_TEMPLATE = """
[Build {project_name} {build_version} {status}]({build_url}):
* **Commit**: [{commit_id}: {commit_message}]({commit_url}) by {committer_name}
-* **Started**: {started}
-* **Finished**: {finished}
+* **Started**: <time:{started}>
+* **Finished**: <time:{finished}>
""".strip()