Rename 'functions' directory to 'internal'

This commit is contained in:
James M. Greene
2023-04-18 00:32:13 -05:00
parent efce2761be
commit 6657d340c9
8 changed files with 14 additions and 14 deletions

16
dist/index.js generated vendored
View File

@@ -9781,7 +9781,7 @@ function wrappy (fn, cb) {
/***/ }),
/***/ 1260:
/***/ 572:
/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => {
const core = __nccwpck_require__(2186)
@@ -9791,7 +9791,7 @@ const { RequestError } = __nccwpck_require__(537)
const HttpStatusMessages = __nccwpck_require__(3703)
// All variables we need from the runtime are loaded here
const getContext = __nccwpck_require__(7705)
const getContext = __nccwpck_require__(8454)
async function processRuntimeResponse(res, requestOptions) {
// Parse the response body as JSON
@@ -9958,7 +9958,7 @@ module.exports = {
/***/ }),
/***/ 7705:
/***/ 8454:
/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => {
const core = __nccwpck_require__(2186)
@@ -9995,19 +9995,19 @@ module.exports = function getContext() {
/***/ }),
/***/ 8782:
/***/ 2634:
/***/ ((module, __unused_webpack_exports, __nccwpck_require__) => {
const core = __nccwpck_require__(2186)
// All variables we need from the runtime are loaded here
const getContext = __nccwpck_require__(7705)
const getContext = __nccwpck_require__(8454)
const {
getSignedArtifactUrl,
createPagesDeployment,
getPagesDeploymentStatus,
cancelPagesDeployment
} = __nccwpck_require__(1260)
} = __nccwpck_require__(572)
const temporaryErrorStatus = {
unknown_status: 'Unable to get deployment status.',
@@ -10414,8 +10414,8 @@ var __webpack_exports__ = {};
const core = __nccwpck_require__(2186)
const { Deployment } = __nccwpck_require__(8782)
const getContext = __nccwpck_require__(7705)
const { Deployment } = __nccwpck_require__(2634)
const getContext = __nccwpck_require__(8454)
const deployment = new Deployment()

2
dist/index.js.map generated vendored

File diff suppressed because one or more lines are too long

View File

@@ -16,7 +16,7 @@ describe('with all environment variables set', () => {
})
it('executes cleanly', done => {
const ip = path.join(__dirname, '../src/index.js')
const ip = path.join(__dirname, '../index.js')
cp.exec(`node ${ip}`, { env: process.env }, (err, stdout) => {
expect(stdout).toMatch(/::debug::all variables are set/)
done()
@@ -27,7 +27,7 @@ describe('with all environment variables set', () => {
describe('with variables missing', () => {
it('execution fails if there are missing variables', done => {
delete process.env.ACTIONS_RUNTIME_URL
const ip = path.join(__dirname, '../src/index.js')
const ip = path.join(__dirname, '../index.js')
cp.exec(`node ${ip}`, { env: process.env }, (err, stdout) => {
expect(stdout).toBe('')
expect(err).toBeTruthy()

View File

@@ -1,7 +1,7 @@
const core = require('@actions/core')
const nock = require('nock')
const { Deployment } = require('../../src/functions/deployment')
const { Deployment } = require('../../internal/deployment')
const fakeJwt =
'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJqdGkiOiJiNjllMWIxOC1jOGFiLTRhZGQtOGYxOC03MzVlMzVjZGJhZjAiLCJzdWIiOiJyZXBvOnBhcGVyLXNwYS9taW55aTplbnZpcm9ubWVudDpQcm9kdWN0aW9uIiwiYXVkIjoiaHR0cHM6Ly9naXRodWIuY29tL3BhcGVyLXNwYSIsInJlZiI6InJlZnMvaGVhZHMvbWFpbiIsInNoYSI6ImEyODU1MWJmODdiZDk3NTFiMzdiMmM0YjM3M2MxZjU3NjFmYWM2MjYiLCJyZXBvc2l0b3J5IjoicGFwZXItc3BhL21pbnlpIiwicmVwb3NpdG9yeV9vd25lciI6InBhcGVyLXNwYSIsInJ1bl9pZCI6IjE1NDY0NTkzNjQiLCJydW5fbnVtYmVyIjoiMzQiLCJydW5fYXR0ZW1wdCI6IjIiLCJhY3RvciI6IllpTXlzdHkiLCJ3b3JrZmxvdyI6IkNJIiwiaGVhZF9yZWYiOiIiLCJiYXNlX3JlZiI6IiIsImV2ZW50X25hbWUiOiJwdXNoIiwicmVmX3R5cGUiOiJicmFuY2giLCJlbnZpcm9ubWVudCI6IlByb2R1Y3Rpb24iLCJqb2Jfd29ya2Zsb3dfcmVmIjoicGFwZXItc3BhL21pbnlpLy5naXRodWIvd29ya2Zsb3dzL2JsYW5rLnltbEByZWZzL2hlYWRzL21haW4iLCJpc3MiOiJodHRwczovL3Rva2VuLmFjdGlvbnMuZ2l0aHVidXNlcmNvbnRlbnQuY29tIiwibmJmIjoxNjM4ODI4MDI4LCJleHAiOjE2Mzg4Mjg5MjgsImlhdCI6MTYzODgyODYyOH0.1wyupfxu1HGoTyIqatYg0hIxy2-0bMO-yVlmLSMuu2w'

View File

@@ -4,8 +4,8 @@
const core = require('@actions/core')
const { Deployment } = require('./functions/deployment')
const getContext = require('./functions/context')
const { Deployment } = require('./internal/deployment')
const getContext = require('./internal/context')
const deployment = new Deployment()