mirror of
https://github.com/Fishwaldo/rundeck-api-java-client.git
synced 2025-07-14 00:48:27 +00:00
Support keyed config get/set/delete for apiv11
This commit is contained in:
parent
29459d9ee1
commit
f49aa63043
10 changed files with 430 additions and 0 deletions
|
@ -116,6 +116,35 @@ public class RundeckClientTest {
|
|||
Assert.assertEquals("a big amazing thingy so there.", result.getProperties().get("blha.blee"));
|
||||
}
|
||||
|
||||
@Test
|
||||
@Betamax(tape = "get_project_config_keyedv11")
|
||||
public void getProjectConfigKeyed() throws Exception {
|
||||
String value = createClient(TEST_TOKEN_6, 11).getProjectConfig("ABC", "project.name");
|
||||
Assert.assertNotNull(value);
|
||||
Assert.assertEquals("ABC", value);
|
||||
}
|
||||
@Test
|
||||
@Betamax(tape = "get_project_config_keyed_dne_v11")
|
||||
public void getProjectConfigKeyedDNE() throws Exception {
|
||||
String value = createClient(TEST_TOKEN_6, 11).getProjectConfig("ABC", "does-not-exist");
|
||||
Assert.assertNull(value);
|
||||
}
|
||||
@Test
|
||||
@Betamax(tape = "set_project_config_keyedv11")
|
||||
public void setProjectConfigKeyed() throws Exception {
|
||||
String value = createClient(TEST_TOKEN_6, 11).setProjectConfig("ABC", "monkey-burrito", "lemon pie");
|
||||
Assert.assertNotNull(value);
|
||||
Assert.assertEquals("lemon pie", value);
|
||||
}
|
||||
@Test
|
||||
@Betamax(tape = "delete_project_config_keyedv11")
|
||||
public void deleteProjectConfigKeyed() throws Exception {
|
||||
RundeckClient client1 = createClient(TEST_TOKEN_6, 11);
|
||||
Assert.assertEquals("7up", client1.setProjectConfig("ABC", "monkey-burrito", "7up"));
|
||||
client1.deleteProjectConfig("ABC", "monkey-burrito");
|
||||
String value=client1.getProjectConfig("ABC", "monkey-burrito");
|
||||
Assert.assertNull(value);
|
||||
}
|
||||
@Test
|
||||
@Betamax(tape = "get_history")
|
||||
public void getHistory() throws Exception {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue