From 5623b2ec3c05dac5b220fcf302d9bbbf9f199dde Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maciej=20S=C5=82awik?= Date: Mon, 6 Feb 2023 08:32:55 +0100 Subject: [PATCH] Lighthouse - send png instead of html --- recipe/custom/lighthouse.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipe/custom/lighthouse.php b/recipe/custom/lighthouse.php index 52bbd77..e2cf436 100644 --- a/recipe/custom/lighthouse.php +++ b/recipe/custom/lighthouse.php @@ -98,7 +98,7 @@ public function validate(): bool --output-path={$lighthouseConfig->getProjectSlug()}-mobile.html {$extraHeaders}"); runLocally("chromium-browser --no-sandbox --headless --screenshot=\"{$lighthouseConfig->getProjectSlug()}-mobile.png\" \ \"{$lighthouseConfig->getProjectSlug()}-mobile.html\""); - runLocally("curl -F file=@{$lighthouseConfig->getProjectSlug()}-mobile.html \ + runLocally("curl -F file=@{$lighthouseConfig->getProjectSlug()}-mobile.png \ -F \"initial_comment=Here are the mobile :iphone: Lighthouse results for your latest deployment :rocket:\" \ -F channels={$lighthouseConfig->getSlackChannels()} \ -H \"Authorization: Bearer {$lighthouseConfig->getSlackAuthToken()}\" \ @@ -110,7 +110,7 @@ public function validate(): bool --output-path={$lighthouseConfig->getProjectSlug()}-desktop.html {$extraHeaders}"); runLocally("chromium-browser --no-sandbox --headless --screenshot=\"{$lighthouseConfig->getProjectSlug()}-desktop.png\" \ \"{$lighthouseConfig->getProjectSlug()}-desktop.html\""); - runLocally("curl -F file=@{$lighthouseConfig->getProjectSlug()}-desktop.html \ + runLocally("curl -F file=@{$lighthouseConfig->getProjectSlug()}-desktop.png \ -F \"initial_comment=Here are the desktop :computer: Lighthouse results for your latest deployment :rocket:\" \ -F channels={$lighthouseConfig->getSlackChannels()} \ -H \"Authorization: Bearer {$lighthouseConfig->getSlackAuthToken()}\" \