This repository has been archived by the owner on May 22, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: unzip every function into their own folder in tests (#1420)
* chore: unzip every function into their own folder in tests * chore: simplify list functions tests * chore: fix tests * chore: fix windows tests * chore: changes * chore: assert that zip file exists * chore: test * chore: simplify
- Loading branch information
Showing
14 changed files
with
1,634 additions
and
845 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,121 @@ | ||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html | ||
|
||
exports[`listFunctions > Can list function main files from multiple source directories with listFunctions() 1`] = ` | ||
[ | ||
{ | ||
"displayName": undefined, | ||
"extension": ".js", | ||
"generator": undefined, | ||
"mainFile": ".netlify/internal-functions/function.js", | ||
"name": "function", | ||
"runtime": "js", | ||
"schedule": undefined, | ||
"srcFile": undefined, | ||
}, | ||
{ | ||
"displayName": undefined, | ||
"extension": ".js", | ||
"generator": undefined, | ||
"mainFile": ".netlify/internal-functions/function_internal.js", | ||
"name": "function_internal", | ||
"runtime": "js", | ||
"schedule": undefined, | ||
"srcFile": undefined, | ||
}, | ||
{ | ||
"displayName": undefined, | ||
"extension": ".js", | ||
"generator": undefined, | ||
"mainFile": "netlify/functions/function.js", | ||
"name": "function", | ||
"runtime": "js", | ||
"schedule": undefined, | ||
"srcFile": undefined, | ||
}, | ||
{ | ||
"displayName": undefined, | ||
"extension": ".js", | ||
"generator": undefined, | ||
"mainFile": "netlify/functions/function_user.js", | ||
"name": "function_user", | ||
"runtime": "js", | ||
"schedule": undefined, | ||
"srcFile": undefined, | ||
}, | ||
] | ||
`; | ||
|
||
exports[`listFunctions > Can list function main files with listFunctions() 1`] = ` | ||
[ | ||
{ | ||
"displayName": undefined, | ||
"extension": ".zip", | ||
"generator": undefined, | ||
"mainFile": "test.zip", | ||
"name": "test", | ||
"runtime": "js", | ||
"schedule": undefined, | ||
"srcFile": undefined, | ||
}, | ||
{ | ||
"displayName": undefined, | ||
"extension": ".js", | ||
"generator": undefined, | ||
"mainFile": "test.js", | ||
"name": "test", | ||
"runtime": "js", | ||
"schedule": undefined, | ||
"srcFile": undefined, | ||
}, | ||
{ | ||
"displayName": undefined, | ||
"extension": ".ts", | ||
"generator": undefined, | ||
"mainFile": "five/index.ts", | ||
"name": "five", | ||
"runtime": "js", | ||
"schedule": undefined, | ||
"srcFile": undefined, | ||
}, | ||
{ | ||
"displayName": undefined, | ||
"extension": ".js", | ||
"generator": undefined, | ||
"mainFile": "four.js/four.js.js", | ||
"name": "four", | ||
"runtime": "js", | ||
"schedule": undefined, | ||
"srcFile": undefined, | ||
}, | ||
{ | ||
"displayName": undefined, | ||
"extension": ".js", | ||
"generator": undefined, | ||
"mainFile": "one/index.js", | ||
"name": "one", | ||
"runtime": "js", | ||
"schedule": undefined, | ||
"srcFile": undefined, | ||
}, | ||
{ | ||
"displayName": undefined, | ||
"extension": ".js", | ||
"generator": undefined, | ||
"mainFile": "two/two.js", | ||
"name": "two", | ||
"runtime": "js", | ||
"schedule": undefined, | ||
"srcFile": undefined, | ||
}, | ||
{ | ||
"displayName": undefined, | ||
"extension": "", | ||
"generator": undefined, | ||
"mainFile": "test", | ||
"name": "test", | ||
"runtime": "go", | ||
"schedule": undefined, | ||
"srcFile": undefined, | ||
}, | ||
] | ||
`; |
Oops, something went wrong.
fd7225f
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
⏱ Benchmark results