Skip to content

Commit

Permalink
fix build script
Browse files Browse the repository at this point in the history
Signed-off-by: Michael Sverdlov <[email protected]>
  • Loading branch information
sverdlov93 committed Sep 12, 2023
1 parent 3fd5363 commit d474553
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions xray/utils/analyzermanager_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,13 +79,15 @@ func TestExtractRelativePath(t *testing.T) {
expectedResult string
}{
{secretPath: "file:///Users/user/Desktop/secrets_scanner/tests/req.nodejs/file.js",
projectPath: "Users/user/Desktop/secrets_scanner/", expectedResult: "/tests/req.nodejs/file.js"},
projectPath: "Users/user/Desktop/secrets_scanner/", expectedResult: "tests/req.nodejs/file.js"},
{secretPath: "invalidSecretPath",
projectPath: "Users/user/Desktop/secrets_scanner/", expectedResult: "invalidSecretPath"},
{secretPath: "",
projectPath: "Users/user/Desktop/secrets_scanner/", expectedResult: ""},
{secretPath: "file:///Users/user/Desktop/secrets_scanner/tests/req.nodejs/file.js",
projectPath: "invalidProjectPath", expectedResult: "/Users/user/Desktop/secrets_scanner/tests/req.nodejs/file.js"},
projectPath: "invalidProjectPath", expectedResult: "Users/user/Desktop/secrets_scanner/tests/req.nodejs/file.js"},
{secretPath: "file:///private/Users/user/Desktop/secrets_scanner/tests/req.nodejs/file.js",
projectPath: "invalidProjectPath", expectedResult: "Users/user/Desktop/secrets_scanner/tests/req.nodejs/file.js"},
}

for _, test := range tests {
Expand Down

0 comments on commit d474553

Please sign in to comment.