mirror of
https://github.com/github/codeql.git
synced 2026-04-26 17:25:19 +02:00
Add missing tests and models for json-patch
This commit is contained in:
@@ -11,3 +11,7 @@ extensions:
|
||||
- ["github.com/evanphx/json-patch/$ANYVERSION", "Patch", True, "Apply", "", "", "Argument[0]", "ReturnValue[0]", "taint", "manual"]
|
||||
- ["github.com/evanphx/json-patch/$ANYVERSION", "Patch", True, "ApplyIndent", "", "", "Argument[-1]", "ReturnValue[0]", "taint", "manual"]
|
||||
- ["github.com/evanphx/json-patch/$ANYVERSION", "Patch", True, "ApplyIndent", "", "", "Argument[0]", "ReturnValue[0]", "taint", "manual"]
|
||||
- ["github.com/evanphx/json-patch/$ANYVERSION", "Patch", True, "ApplyWithOptions", "", "", "Argument[-1]", "ReturnValue[0]", "taint", "manual"]
|
||||
- ["github.com/evanphx/json-patch/$ANYVERSION", "Patch", True, "ApplyWithOptions", "", "", "Argument[0]", "ReturnValue[0]", "taint", "manual"]
|
||||
- ["github.com/evanphx/json-patch/$ANYVERSION", "Patch", True, "ApplyIndentWithOptions", "", "", "Argument[-1]", "ReturnValue[0]", "taint", "manual"]
|
||||
- ["github.com/evanphx/json-patch/$ANYVERSION", "Patch", True, "ApplyIndentWithOptions", "", "", "Argument[0]", "ReturnValue[0]", "taint", "manual"]
|
||||
|
||||
@@ -61,4 +61,18 @@ func main() {
|
||||
|
||||
b11, _ := getTaintedPatch().ApplyIndent(untaintedByteArray, " ")
|
||||
sinkByteArray(b11) // $ taintflow
|
||||
|
||||
// func (p Patch) ApplyWithOptions(doc []byte, options *ApplyOptions) ([]byte, error)
|
||||
b12, _ := untaintedPatch.ApplyWithOptions(getTaintedByteArray(), nil)
|
||||
sinkByteArray(b12) // $ taintflow
|
||||
|
||||
b13, _ := getTaintedPatch().ApplyWithOptions(untaintedByteArray, nil)
|
||||
sinkByteArray(b13) // $ taintflow
|
||||
|
||||
// func (p Patch) ApplyIndentWithOptions(doc []byte, indent string, options *ApplyOptions) ([]byte, error)
|
||||
b14, _ := untaintedPatch.ApplyIndentWithOptions(getTaintedByteArray(), " ", nil)
|
||||
sinkByteArray(b14) // $ taintflow
|
||||
|
||||
b15, _ := getTaintedPatch().ApplyIndentWithOptions(untaintedByteArray, " ", nil)
|
||||
sinkByteArray(b15) // $ taintflow
|
||||
}
|
||||
|
||||
@@ -54,3 +54,14 @@ func (_ Patch) Apply(_ []byte) ([]byte, error) {
|
||||
func (_ Patch) ApplyIndent(_ []byte, _ string) ([]byte, error) {
|
||||
return nil, nil
|
||||
}
|
||||
|
||||
type ApplyOptions struct {
|
||||
}
|
||||
|
||||
func (_ Patch) ApplyWithOptions(_ []byte, _ *ApplyOptions) ([]byte, error) {
|
||||
return nil, nil
|
||||
}
|
||||
|
||||
func (_ Patch) ApplyIndentWithOptions(_ []byte, _ string, _ *ApplyOptions) ([]byte, error) {
|
||||
return nil, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user