title: Incorrect properties displayed from Json
body: <p>I am having an issue when trying to collect data from a json using SOAP UI and groovy scripting. Below is an example json:</p>
  
  <pre><code>{
      "regions": [{
          "hotels": [{
                  "roomInformation": [{
                      "hotelRoomId": xxx,
                  }],
                  "regionId": x,
                  "hotelId": xxx,                 
                  "providerInformation": {
                      "ratePlanCode": "xxx",
                  },
                  "providerHotelId": 0000001
              },
  
              {
                  "roomInformation": [{
                      "hotelRoomId": xx,
                  }],
                  "regionId": x,
                  "hotelId": xxx,                 
                  "providerInformation": {
                      "ratePlanCode": "ggg",
                  },
                  "providerHotelId": 0000002
              }
          ],
          "errors": null
      }],
      "errors": null
  }
  </code></pre>
  
  <p>What I want to do is select the first instance of <code>providerHotelId</code> and <code>ratePlanCode</code>. To do this I have the groovy script below to tackle this:</p>
  
  <pre><code>def alert = com.eviware.soapui.support.UISupport
  import groovy.json.JsonSlurper
  def response = testRunner.testCase.getTestStepByName("Search Test").getProperty("Response").getValue();
  
  def jsonRes = new JsonSlurper().parseText(response);
  
  def providerhotelid = jsonRes.regions.hotels.providerHotelId[0].toString()
  def rateplancode = jsonRes.regions.hotels.providerInformation[0].ratePlanCode.toString()
  
  log.info providerhotelid
  
  testRunner.testCase.setPropertyValue('providerhotelid', providerhotelid)
  testRunner.testCase.setPropertyValue('rateplancode', rateplancode) 
  </code></pre>
  
  <p>This outputs below in my custom properties:</p>
  
  <ul>
  <li>providerhotelid - [0000001,0000002]</li>
  <li>rateplancode - [xxx]</li>
  </ul>
  
  <p>The above is incorrect because:</p>
  
  <ol>
  <li><strong>providerhotelid</strong> - it displays all provider hotel ids when I only want the first one which should be <code>0000001</code>.</li>
  <li><strong>rateplancode</strong> - is correct but it displays a [] around it and I want this removed. Same goes for providerhotelid.</li>
  </ol>
  
  <p>So for this example my custom properties should display:</p>
  
  <ul>
  <li>providerhotelid - 0000001</li>
  <li>rateplancode - xxx</li>
  </ul>
  
  <p>How can this be achieved within my groovy script?</p>