List of usage examples for org.springframework.vault.support VaultResponse VaultResponse
VaultResponse
From source file:de.dominikschadow.configclient.secret.SecretControllerTest.java
@Test public void getSecretForUserReturnsOk() throws Exception { VaultResponse vaultResponse = new VaultResponse(); String path = SecretController.SECRET_BASE_PATH + "12345"; given(vaultTemplate.read(path)).willReturn(vaultResponse); mvc.perform(MockMvcRequestBuilders.get("/secrets/12345")).andExpect(MockMvcResultMatchers.status().isOk()); }
From source file:de.dominikschadow.configclient.secret.SecretControllerTest.java
@Test public void getSecretContentForUserReturnsOk() throws Exception { VaultResponse vaultResponse = new VaultResponse(); String path = SecretController.SECRET_BASE_PATH + "12345"; given(vaultTemplate.read(path)).willReturn(vaultResponse); mvc.perform(MockMvcRequestBuilders.get("/secrets/12345?type=content")) .andExpect(MockMvcResultMatchers.status().isOk()); }