/**
   * Uses Nested Search Criteria for inheritance as association in search Verifies that the results
   * are returned Verifies size of the result set Verifies that none of the attribute is null
   *
   * @throws Exception
   */
  public void testAssociationNestedSearch2() throws Exception {
    CRTMonitor searchObject = new CRTMonitor();
    searchObject.setBrand("A");
    Collection results =
        getApplicationService()
            .search(
                "gov.nih.nci.cacoresdk.domain.inheritance.twolevelinheritance.Monitor",
                searchObject);

    assertNotNull(results);
    assertEquals(1, results.size());

    for (Iterator i = results.iterator(); i.hasNext(); ) {
      Monitor result = (Monitor) i.next();
      toXML(result);
      Monitor result2 = (Monitor) fromXML(result);

      assertNotNull(result2);
      assertNotNull(result2.getId());
      assertNotNull(result2.getHeight());
      assertNotNull(result2.getWidth());
      assertNotNull(result2.getBrand());
    }
  }