title: How do implement step definition in multiple lines?
body: <p>I am using Scala, Cucumber, Gherkin language for automation test. I've the following scenario in my feature file, written in Gherkin language:   </p>
  
  <pre><code>Scenario Outline: Do something
    When I do something  
    Then result should have field1 as "&lt;filed_1&gt;", field2 as "&lt;filed_2&gt;" and filed3 as "&lt;filed_3&gt;"
  </code></pre>
  
  <p>And the stepdef generated is:</p>
  
  <pre><code>When("""^I do something$""") {
          // do operation
  }
  Then("""^result should haveresult should have field1 as "([^"]*)", 
      field2 as "([^"]*)" and filed3 as "([^"]*)"$""") {
       // do operation
  }
  </code></pre>
  
  <p>Here <strong><em>Then</em></strong> statement having more than 120 characters in a line which I have to break in two. I should not be changing feature file.</p>
  
  <p>When break <strong><em>Then</em></strong> in two lines </p>
  
  <pre><code>Then("""^result should haveresult should have field1 as "([^"]*)", 
        | field2 as "([^"]*)" and filed3 as "([^"]*)"$""".stripMargin)
  </code></pre>
  
  <p>It saying You can implement missing steps with the snippets below:</p>
  
  <pre><code>Then("""^result should have field1 as "([^"]*)", field2 as "([^"]*)" and filed3 as "([^"]*)"$"""){ (arg0:String, arg1:String, arg2:String) =&gt;
    //// Write code here that turns the phrase above into concrete actions
    throw new PendingException()
  } 
  </code></pre>
  
  <p>I am not sure which approach should I be taking to break <strong><em>Then</em></strong> in multiple lines. Appreciate any help.</p>