-
Notifications
You must be signed in to change notification settings - Fork 93
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
…2019) * Checking artifacts before snippet * code review - 1 * code review - 1 * code review - 2 * Code review - 2 * code review - 3 * code review - 3
- Loading branch information
Showing
4 changed files
with
175 additions
and
12 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
28 changes: 28 additions & 0 deletions
28
...l/ValidateCommand/ExpectedOutputs/SARIF2010.ProvideCodeSnippets_WithEmbeddedContent.sarif
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,28 @@ | ||
{ | ||
"$schema": "https://schemastore.azurewebsites.net/schemas/json/sarif-2.1.0-rtm.5.json", | ||
"version": "2.1.0", | ||
"runs": [ | ||
{ | ||
"tool": { | ||
"driver": { | ||
"name": "SARIF Functional Testing" | ||
} | ||
}, | ||
"invocations": [ | ||
{ | ||
"executionSuccessful": true | ||
} | ||
], | ||
"artifacts": [ | ||
{ | ||
"location": { | ||
"uri": "FunctionalTestOutput.ValidateCommand/Inputs.SARIF2010.ProvideCodeSnippets_WithArtifacts_Valid.sarif", | ||
"uriBaseId": "TEST_DIR" | ||
} | ||
} | ||
], | ||
"results": [], | ||
"columnKind": "utf16CodeUnits" | ||
} | ||
] | ||
} |
71 changes: 71 additions & 0 deletions
71
.../Multitool/ValidateCommand/Inputs/SARIF2010.ProvideCodeSnippets_WithEmbeddedContent.sarif
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,71 @@ | ||
{ | ||
"$schema": "https://schemastore.azurewebsites.net/schemas/json/sarif-2.1.0-rtm.5.json", | ||
"version": "2.1.0", | ||
"runs": [ | ||
{ | ||
"tool": { | ||
"driver": { | ||
"name": "CodeScanner", | ||
"version": "1.0" | ||
} | ||
}, | ||
"originalUriBaseIds": { | ||
"TEST_ROOT": { | ||
"uri": "file://c:/test/" | ||
} | ||
}, | ||
"artifacts": [ | ||
{ | ||
"contents": { | ||
"text": "File Source" | ||
}, | ||
"location": { | ||
"uri": "src/test.c" | ||
} | ||
}, | ||
{ | ||
"contents": { | ||
"text": "File Source" | ||
}, | ||
"location": { | ||
"uri": "test2.c", | ||
"uriBaseId": "TEST_ROOT" | ||
} | ||
} | ||
], | ||
"results": [ | ||
{ | ||
"ruleId": "TST0001", | ||
"level": "error", | ||
"message": { | ||
"text": "Some testing occurred." | ||
}, | ||
"locations": [ | ||
{ | ||
"physicalLocation": { | ||
"artifactLocation": { | ||
"uri": "src/test.c" | ||
}, | ||
"properties": { | ||
"comment": "This test will NOT generate a valid AbsoluteUri, but it will find in artifacts. So it doesn't need a snippet." | ||
} | ||
} | ||
}, | ||
{ | ||
"physicalLocation": { | ||
"artifactLocation": { | ||
"uri": "test2.c", | ||
"uriBaseId": "TEST_ROOT" | ||
}, | ||
"properties": { | ||
"comment": "This test will generate a valid AbsoluteUri and it will find in artifacts. So it doesn't need a snippet." | ||
} | ||
} | ||
} | ||
] | ||
} | ||
], | ||
"columnKind": "utf16CodeUnits" | ||
} | ||
] | ||
} |