title: Parameterized Variables for use in Assertion Groovy Script
body: <p>Essentially, I am using SoapUI for some smoke testing and have created an assertion script that checks if there is data within an SQL database.</p>
  
  <p>This test has to be ran on three different environments, each with their individual database credentials.</p>
  
  <p>What I would like to do is create a Custom Property (or set of custom properties) in the test class that holds the three sets of database information to allow a tester to simply select which environment they're testing rather than having to change the hard-coded assertion script.</p>
  
  <p>The code:</p>
  
  <pre><code>import groovy.sql.Sql    
  import oracle.jdbc.driver.OracleDriver
  
  def con = Sql.newinstance('"server", "user",
                                "pass", "oracle.jdbc.driver.OracleDriver"')
  
  def res = con.rows("select * from table1 where message_in = 'Bang'")
  
  log.info(res[0])
  
  con.close()
  
  assert res[0] != null
  </code></pre>