Search in sources :

Example 1 with ReadFileStep

use of org.jenkinsci.plugins.workflow.steps.ReadFileStep in project workflow-cps-plugin by jenkinsci.

the class SnippetizerTest method basics.

@Test
public void basics() throws Exception {
    st.assertRoundTrip(new EchoStep("hello world"), "echo 'hello world'");
    ReadFileStep s = new ReadFileStep("build.properties");
    st.assertRoundTrip(s, "readFile 'build.properties'");
    s.setEncoding("ISO-8859-1");
    st.assertRoundTrip(s, "readFile encoding: 'ISO-8859-1', file: 'build.properties'");
}
Also used : EchoStep(org.jenkinsci.plugins.workflow.steps.EchoStep) ReadFileStep(org.jenkinsci.plugins.workflow.steps.ReadFileStep) Test(org.junit.Test)

Aggregations

EchoStep (org.jenkinsci.plugins.workflow.steps.EchoStep)1 ReadFileStep (org.jenkinsci.plugins.workflow.steps.ReadFileStep)1 Test (org.junit.Test)1