mirror of
https://github.com/cloudflare/wrangler-action.git
synced 2024-11-25 11:24:46 +01:00
fix(test): Fix execution for fake wrangler installation
This commit is contained in:
parent
992c58e932
commit
afaec62104
4 changed files with 8 additions and 9 deletions
|
@ -1,4 +0,0 @@
|
||||||
#!/usr/bin/env node
|
|
||||||
"use strict";
|
|
||||||
|
|
||||||
require("../index");
|
|
9
test/pre-installed-wrangler/mock_packages/wrangler/index.js
Normal file → Executable file
9
test/pre-installed-wrangler/mock_packages/wrangler/index.js
Normal file → Executable file
|
@ -1,10 +1,13 @@
|
||||||
|
#!/usr/bin/env node
|
||||||
|
"use strict";
|
||||||
|
|
||||||
const args = Array.from(process.argv);
|
const args = Array.from(process.argv);
|
||||||
const command = args.pop();
|
const command = args.pop();
|
||||||
switch (command) {
|
switch (command) {
|
||||||
case "--version":
|
case "--version":
|
||||||
console.log(
|
console.log(`
|
||||||
"⛅️ wrangler 1.1.1 (update available 1.2.3)\n" +
|
⛅️ wrangler 1.1.1 (update available 1.2.3)
|
||||||
"-------------------------------------------------------",
|
------------------------------------------`
|
||||||
);
|
);
|
||||||
process.exit(0);
|
process.exit(0);
|
||||||
case "action-test":
|
case "action-test":
|
||||||
|
|
|
@ -3,5 +3,5 @@
|
||||||
"name": "wrangler",
|
"name": "wrangler",
|
||||||
"version": "1.1.1",
|
"version": "1.1.1",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"bin": "bin/wrangler"
|
"bin": "index.js"
|
||||||
}
|
}
|
||||||
|
|
2
test/pre-installed-wrangler/package-lock.json
generated
2
test/pre-installed-wrangler/package-lock.json
generated
|
@ -14,7 +14,7 @@
|
||||||
"version": "1.1.1",
|
"version": "1.1.1",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"bin": {
|
"bin": {
|
||||||
"wrangler": "bin/wrangler"
|
"wrangler": "index.js"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/wrangler": {
|
"node_modules/wrangler": {
|
||||||
|
|
Loading…
Reference in a new issue