public class

RundeckClientTest

extends Object
java.lang.Object
   ↳ org.rundeck.api.RundeckClientTest

Class Overview

Test the RundeckClient. Uses betamax to unit-test HTTP requests without a live RunDeck instance.

Summary

Constants
String TEST_TOKEN_0 Note: to add a new test, do the following: 1) start a rundeck server, available at hostname "rundeck.local" 2) login as test or admin user, and generate a token 3) add the test token as a new TEST_TOKEN_X, and use that in your test 4) run 'mvn test', and commit the new yml file generated at src/test/resources/betamax/tapes
String TEST_TOKEN_1
String TEST_TOKEN_2
String TEST_TOKEN_3
String TEST_TOKEN_4
String TEST_TOKEN_5
String TEST_TOKEN_6
Fields
public Recorder recorder
Public Constructors
RundeckClientTest()
Public Methods
void abortExecution()
void abortExecutionAsUser()
void abortExecutionAsUserUnauthorized()
void apiVersionDefaultLatest()
void bulkDelete()
void bulkDeleteFailDNE()
void bulkDeleteFailUnauthorized()
void executionOutputBasic()
Execution output
void executionOutputForNode()
Execution output for a node
void executionOutputForNodeAndStep()
Execution output for a node and step
void executionOutputForStep()
Execution output for a step
void executionOutputState()
Execution output state sequence
void executionOutputStateOnly()
Execution output state sequence
void executionState()
Execution state structure
void getExecutions()
void getExecutionsPaging()
Test paging values from results
void getHistory()
void getHistoryExcludeJoblist()
void getHistoryJoblist()
void getHistoryUser()
void getProjects()
void importJobsContextProject()
Import jobs, xml contains project context
void importJobsNoProject()
Import jobs, xml no project defined
void importJobsProjectParam()
Import jobs, using project parameter
void importJobsProjectParamOverride()
Import jobs, project parameter overrides xml
void importJobsProjectParamV7()
Import jobs, project parameter v7 doesn' use parameter
void importJobsUUIDParamPreserveV9()
Import jobs, project parameter v7 doesn' use parameter
void importJobsUUIDParamRemoveV9()
Import jobs, project parameter v7 doesn' use parameter
void runningExecutionsV8()
Running executions for all projects using API v8, which queries for project list and then individually queries each project's now running
void runningExecutionsV9()
Running executions for all projects using API v9
void setUp()
void triggerAdhocCommand()
void triggerAdhocCommandAsUser()
void triggerAdhocCommandAsUserUnauthorized()
void triggerAdhocScript()
void triggerAdhocScriptAsUser()
void triggerAdhocScriptAsUserUnauthorized()
void triggerAdhocScriptInpterpreter()
void triggerJobAsUser()
void triggerJobAsUserUnauthorized()
void triggerJobBasic()
[Expand]
Inherited Methods
From class java.lang.Object

Constants

public static final String TEST_TOKEN_0

Note: to add a new test, do the following: 1) start a rundeck server, available at hostname "rundeck.local" 2) login as test or admin user, and generate a token 3) add the test token as a new TEST_TOKEN_X, and use that in your test 4) run 'mvn test', and commit the new yml file generated at src/test/resources/betamax/tapes

See Also
  • createClient(String)
Constant Value: "PVnN5K3OPc5vduS3uVuVnEsD57pDC5pd"

public static final String TEST_TOKEN_1

Constant Value: "0UUNkeRp4d58EDeCs7S6UdODp334DvK9"

public static final String TEST_TOKEN_2

Constant Value: "PP4s4SdCRO6KUoNPd1D303Dc304ORN87"

public static final String TEST_TOKEN_3

Constant Value: "9RdEosesKP3se4oV9EKOd4s3RUeUS3ON"

public static final String TEST_TOKEN_4

Constant Value: "sN5RRSNvu15DnV6EcNDdc2CkdPcv3s32"

public static final String TEST_TOKEN_5

Constant Value: "C3O6d5O98Kr6Dpv71sdE4ERdCuU12P6d"

public static final String TEST_TOKEN_6

Constant Value: "Do4d3NUD5DKk21DR4sNK755RcPk618vn"

Fields

public Recorder recorder

Public Constructors

public RundeckClientTest ()

Public Methods

public void abortExecution ()

Throws
Exception

public void abortExecutionAsUser ()

Throws
Exception

public void abortExecutionAsUserUnauthorized ()

Throws
Exception

public void apiVersionDefaultLatest ()

public void bulkDelete ()

Throws
Exception

public void bulkDeleteFailDNE ()

Throws
Exception

public void bulkDeleteFailUnauthorized ()

Throws
Exception

public void executionOutputBasic ()

Execution output

Throws
Exception

public void executionOutputForNode ()

Execution output for a node

Throws
Exception

public void executionOutputForNodeAndStep ()

Execution output for a node and step

Throws
Exception

public void executionOutputForStep ()

Execution output for a step

Throws
Exception

public void executionOutputState ()

Execution output state sequence

Throws
Exception

public void executionOutputStateOnly ()

Execution output state sequence

Throws
Exception

public void executionState ()

Execution state structure

Throws
Exception

public void getExecutions ()

Throws
Exception

public void getExecutionsPaging ()

Test paging values from results

Throws
Exception

public void getHistory ()

Throws
Exception

public void getHistoryExcludeJoblist ()

Throws
Exception

public void getHistoryJoblist ()

Throws
Exception

public void getHistoryUser ()

Throws
Exception

public void getProjects ()

Throws
Exception

public void importJobsContextProject ()

Import jobs, xml contains project context

Throws
Exception

public void importJobsNoProject ()

Import jobs, xml no project defined

Throws
Exception

public void importJobsProjectParam ()

Import jobs, using project parameter

Throws
Exception

public void importJobsProjectParamOverride ()

Import jobs, project parameter overrides xml

Throws
Exception

public void importJobsProjectParamV7 ()

Import jobs, project parameter v7 doesn' use parameter

Throws
Exception

public void importJobsUUIDParamPreserveV9 ()

Import jobs, project parameter v7 doesn' use parameter

Throws
Exception

public void importJobsUUIDParamRemoveV9 ()

Import jobs, project parameter v7 doesn' use parameter

Throws
Exception

public void runningExecutionsV8 ()

Running executions for all projects using API v8, which queries for project list and then individually queries each project's now running

Throws
Exception

public void runningExecutionsV9 ()

Running executions for all projects using API v9

Throws
Exception

public void setUp ()

Throws
Exception

public void triggerAdhocCommand ()

Throws
Exception

public void triggerAdhocCommandAsUser ()

Throws
Exception

public void triggerAdhocCommandAsUserUnauthorized ()

Throws
Exception

public void triggerAdhocScript ()

Throws
Exception

public void triggerAdhocScriptAsUser ()

Throws
Exception

public void triggerAdhocScriptAsUserUnauthorized ()

Throws
Exception

public void triggerAdhocScriptInpterpreter ()

Throws
Exception

public void triggerJobAsUser ()

Throws
Exception

public void triggerJobAsUserUnauthorized ()

Throws
Exception

public void triggerJobBasic ()

Throws
Exception