Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removed 2 unnecessary stubbings in FolderIT.java #319

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,14 @@ private VaultAccessor mockVaultAccessor() {
return vaultAccessor;
}

private VaultAccessor mockVaultAccessor2() {
VaultAccessor vaultAccessor = mock(VaultAccessor.class);
LogicalResponse resp = mock(LogicalResponse.class);
Map<String, String> returnValue = new HashMap<>();
returnValue.put("key1", "some-secret");
return vaultAccessor;
}

private List<VaultSecret> standardSecrets() {
List<VaultSecret> secrets = new ArrayList<>();
VaultSecretValue secretValue = new VaultSecretValue("envVar1", "key1");
Expand Down Expand Up @@ -217,7 +225,7 @@ public void jobInFolderShouldNotBeAbleToAccessCredentialsScopedToAnotherFolder()
List<VaultSecret> secrets = standardSecrets();

VaultBuildWrapper vaultBuildWrapper = new VaultBuildWrapper(secrets);
VaultAccessor mockAccessor = mockVaultAccessor();
VaultAccessor mockAccessor = mockVaultAccessor2();
vaultBuildWrapper.setVaultAccessor(mockAccessor);

VaultConfiguration vaultConfig = new VaultConfiguration();
Expand Down
Loading