Ejemplo n.º 1
0
  /**
   * Removes the text contet added before.
   *
   * <p>Has <b> OK </b> status if the method successfully returns and no exceptions were thrown.
   *
   * <p>The following method tests are to be completed successfully before :
   *
   * <ul>
   *   <li><code> insertTextContent() </code> : inserts the content to be removed in this test.
   * </ul>
   */
  public void _removeTextContent() {

    // leads to a method which should be called previously
    requiredMethod("insertTextContent()");

    // write to log what we try next
    log.println("test for  removeTextContent");
    try {
      oObj.removeTextContent((XTextContent) oInt);
      // oObj.removeTextContent( (XTextContent)oInt );
    } catch (com.sun.star.container.NoSuchElementException nseE) {
      // Some exception.FAILED
      Status.failed(nseE.toString());
      return;
    }

    // no exception occurred so it works
    tRes.tested("removeTextContent()", true);
  }