Skip to content

Commit

Permalink
chore: add another test case
Browse files Browse the repository at this point in the history
  • Loading branch information
jon4hz committed Nov 21, 2024
1 parent f07c1dd commit dec3363
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,20 @@ func TestVaultPath(t *testing.T) {
stringResult: "engine/path/to/secret",
pathResult: "path/to/secret",
},
{
vp: vaultPath{"engine"},
metadataResult: "engine/metadata/",
engineResult: "engine",
stringResult: "engine",
pathResult: "",
},
{
vp: vaultPath{"engine", "path"},
metadataResult: "engine/metadata/path/",
engineResult: "engine",
stringResult: "engine/path",
pathResult: "path",
},
} {
assert.Equal(t, tc.metadataResult, tc.vp.MetadataPath())
assert.Equal(t, tc.engineResult, tc.vp.Engine())
Expand Down

0 comments on commit dec3363

Please sign in to comment.