Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Make additional function attributes available via functions man…
…ifest (#1221) * feat: pass additional-function-attributes * chore: make attributes available to functions manifest * fix: fix linting * fix: use optional chaining * fix: add ext * fix: fix tests * fix: change internal directory name in constants.ts * feat: add test for go functions with displayName and from an internal functions folder * feat: add test for rust functions build from internal folder with displayName property * feat: add test for nodejs functions build from internal folder with displayName property * test: figure out windows breakn * fix: take windows paths into account when checking for internal functions * test: add unit test for checkIsInternalFunction * docs: add new return values * test: move tests into a better fixtures structure * fix: use unixify for checkIsInternalFunction, config, bundler, module and resolve * feat: add internalFunctionsFolder option to zipfunctionoptions * test: fix tests * test: add test for zipFunction and code to support that as well * test: change toBeTruthy to toBe(true) and isInternalFunction to internalFunction * chore: change displayName input to name * chore: change internalFunction to isInternal * chore: revert unixify, rename tests and internalFunctionsFolder to internalSrcFolder * test: revert unixify for module to see if windows test still fails * Revert "test: revert unixify for module to see if windows test still fails" This reverts commit b444d1c. Co-authored-by: khen <30577427+khendrikse@users.noreply.github.com>
- Loading branch information
1 parent
de48712
commit ea4008e
Showing
25 changed files
with
1,722 additions
and
7 deletions.
There are no files selected for viewing
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
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
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
9 changes: 9 additions & 0 deletions
9
tests/fixtures/go-internal/.netlify/internal-functions/go-func-1/main.go
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,9 @@ | ||
package main | ||
|
||
import ( | ||
"fmt" | ||
) | ||
|
||
func main() { | ||
fmt.Println("Hello, world!") | ||
} |
9 changes: 9 additions & 0 deletions
9
tests/fixtures/go-internal/.netlify/internal-functions/go-func-2/go-func-2.go
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,9 @@ | ||
package main | ||
|
||
import ( | ||
"fmt" | ||
) | ||
|
||
func main() { | ||
fmt.Println("Hello, world!") | ||
} |
3 changes: 3 additions & 0 deletions
3
tests/fixtures/go-internal/.netlify/internal-functions/go-func-2/go.mod
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,3 @@ | ||
module github.com/netlify/zip-it-and-ship-it/tests/fixtures/go-source | ||
|
||
go 1.15 |
Empty file.
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 @@ | ||
module.exports = true |
1 change: 1 addition & 0 deletions
1
tests/fixtures/node-internal/.netlify/internal-functions/function-1.js
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 @@ | ||
module.exports = true |
1 change: 1 addition & 0 deletions
1
tests/fixtures/node-internal/.netlify/internal-functions/function-2.js
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 @@ | ||
module.exports = true |
1 change: 1 addition & 0 deletions
1
tests/fixtures/rust-internal/.netlify/internal-functions/rust-func-1/.gitignore
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 @@ | ||
/target |
Oops, something went wrong.
ea4008e
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