From 90e8e1e67353ac01c38e7431dda2422504a6fa30 Mon Sep 17 00:00:00 2001 From: "Thomas A. Christensen II" <25492070+MillironX@users.noreply.github.com> Date: Mon, 13 Jun 2022 16:38:31 -0500 Subject: [PATCH] Add Nextflow smoke test --- index.js | 8 ++++++++ package-lock.json | 1 + package.json | 1 + 3 files changed, 10 insertions(+) diff --git a/index.js b/index.js index 5f1ec8d..03065eb 100644 --- a/index.js +++ b/index.js @@ -1,4 +1,5 @@ const core = require("@actions/core"); +const exec = require("@actions/exec") const fs = require("fs"); const github = require("@actions/github"); const io = require("@actions/io"); @@ -163,6 +164,13 @@ async function run() { } catch (e) { core.setFailed(e.message); } + + // Run Nextflow so it downloads its dependencies + try { + const nf_exit_code = await exec.exec("nextflow", ["help"]) + } catch (e) { + core.warning("Nextflow appears to have installed correctly, but an error was thrown while running it.") + } } run(); diff --git a/package-lock.json b/package-lock.json index faf89ee..1dcc0e5 100644 --- a/package-lock.json +++ b/package-lock.json @@ -10,6 +10,7 @@ "license": "ISC", "dependencies": { "@actions/core": "^1.8.2", + "@actions/exec": "^1.1.1", "@actions/github": "^5.0.3", "@actions/tool-cache": "^2.0.1", "async-retry": "^1.3.3", diff --git a/package.json b/package.json index 8686df6..b242a84 100644 --- a/package.json +++ b/package.json @@ -11,6 +11,7 @@ "license": "ISC", "dependencies": { "@actions/core": "^1.8.2", + "@actions/exec": "^1.1.1", "@actions/github": "^5.0.3", "@actions/tool-cache": "^2.0.1", "async-retry": "^1.3.3",