grafana / grafana/plugin-ci-workflows

Improve support for Playwright tests when using plugin-directory input

Open
#553 1 comment 0 reactions 1 assignee Assigned to @sunker View on GitHub
enhancement
Dominant language
Go
Stars
10
Forks
6
Avg merge
19h 51m
Merged PRs (30d)
97

Description

When the plugin doesn't live in the root of the repository (e.g.: monorepos), the Playwright workflow is not able to correctly resolve the Grafana dependency because the underlying action assumes the plugin is in the root of the repository.

The workaround is specifying the grafana-dependency as an input:

```yaml
with:
plugin-directory: packages/grafana-my-app
package-manager: npm

# The playwright action assumes that the plugin is in the root of the repository
# and gets the Grafana dependency from src/plugin.json. This is not the case for
# this plugin, so we need to explicitly set the Grafana dependency version.
run-playwright-with-grafana-dependency: ">=9.5.2"
```

We should instead find a way to automatically locate the plugin.json file in the folder specified in plugin-directory and use that instead.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.