Merge branch 'main' into cschleiden/support-env-secrets

This commit is contained in:
Christopher Schleiden
2023-01-06 14:45:46 -08:00
committed by GitHub
6 changed files with 39 additions and 13 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@github/actions-languageservice",
"version": "0.1.68",
"version": "0.1.69",
"description": "Language service for GitHub Actions",
"license": "MIT",
"type": "module",
+26
View File
@@ -25,6 +25,32 @@ jobs:
expect(result?.contents).toEqual("Runs your workflow when you push a commit or tag.");
});
it("on a parameter with a description", async () => {
const input = `on: push
jobs:
build:
co|ntinue-on-error: false`;
const result = await hover(...getPositionFromCursor(input));
expect(result).not.toBeUndefined();
expect(result?.contents).toEqual(
"Prevents a workflow run from failing when a job fails. Set to true to allow a workflow run to pass when this job fails.\n\n" +
"**Context:** github, inputs, vars, needs, strategy, matrix"
);
});
it("on a parameter with its own type", async () => {
const input = `on: push
jobs:
build:
pe|rmissions: read-all`;
const result = await hover(...getPositionFromCursor(input));
expect(result).not.toBeUndefined();
expect(result?.contents).toEqual(
"You can modify the default permissions granted to the GITHUB_TOKEN, adding or removing access as required, so that you only allow the minimum required access."
);
});
it("on a value in a sequence", async () => {
const input = `on: [pull_request,
pu|sh]