From 5ed5a2de2ad86b9d8ef244ecd638c1bab5afe9b7 Mon Sep 17 00:00:00 2001 From: Ashley Harrison Date: Thu, 4 Jul 2024 11:19:07 +0100 Subject: [PATCH] Chore: Add timeout for storybook e2e, only run on changes to @grafana/ui (#90035) * add timeout for storybook, only run on changes to @grafana/ui * add comment to trigger verify-storybook * remove test comment * add comment * use a later version of wait-on * remove comment and hardcode wait-on version --- .drone.yml | 13 +++++-------- scripts/drone/events/pr.star | 2 +- scripts/drone/steps/lib.star | 2 +- 3 files changed, 7 insertions(+), 10 deletions(-) diff --git a/.drone.yml b/.drone.yml index 215a0170f95..b916487e018 100644 --- a/.drone.yml +++ b/.drone.yml @@ -135,7 +135,7 @@ steps: image: node:20.9.0-alpine name: start-storybook - commands: - - npx wait-on@7.0.1 http://$HOST:$PORT + - npx wait-on@7.2.0 -t 1m http://$HOST:$PORT - yarn e2e:storybook depends_on: - start-storybook @@ -151,11 +151,8 @@ trigger: exclude: - docs/** - '*.md' - - pkg/** - - packaging/** - - go.sum - - go.mod - include: [] + include: + - packages/grafana-ui/** type: docker volumes: - host: @@ -1910,7 +1907,7 @@ steps: image: node:20.9.0-alpine name: start-storybook - commands: - - npx wait-on@7.0.1 http://$HOST:$PORT + - npx wait-on@7.2.0 -t 1m http://$HOST:$PORT - yarn e2e:storybook depends_on: - start-storybook @@ -5181,6 +5178,6 @@ kind: secret name: gcr_credentials --- kind: signature -hmac: 6c273dec437d3ae5ae9a42450c57956259a691ff0df7c161a57eaa683c867acd +hmac: c4a656d676b1228248f6948ac0347aea1d67016429aa24351d0a5c3e2d7dc617 ... diff --git a/scripts/drone/events/pr.star b/scripts/drone/events/pr.star index a67b0956edc..9a57ec4cc53 100644 --- a/scripts/drone/events/pr.star +++ b/scripts/drone/events/pr.star @@ -87,7 +87,7 @@ def pr_pipelines(): ), verify_storybook( get_pr_trigger( - exclude_paths = ["pkg/**", "packaging/**", "go.sum", "go.mod"], + include_paths = ["packages/grafana-ui/**"], ), ver_mode, ), diff --git a/scripts/drone/steps/lib.star b/scripts/drone/steps/lib.star index 734bb553e20..6c7b29f80cb 100644 --- a/scripts/drone/steps/lib.star +++ b/scripts/drone/steps/lib.star @@ -799,7 +799,7 @@ def e2e_storybook_step(): "PORT": "9001", }, "commands": [ - "npx wait-on@7.0.1 http://$HOST:$PORT", + "npx wait-on@7.2.0 -t 1m http://$HOST:$PORT", "yarn e2e:storybook", ], }