Using the Universal Test Client with WebLogic

IBM Rational Developer provides you with a Web-based Universal Test Client where you can test your enterprise beans and Java classes. See the IBM Rational Developer documentation Using the Universal Test Client for details. If you are running the Universal Test Client on a WebLogic Server, there are some minor differences in how the Universal Test Client is used.

Note: You must start the Universal Test Client by selecting Run on Server or Debug on Server from the context menu of Enterprise Applications, EJB projects or Web projects. This automatically sets the JNDI properties for the Universal Test Client.

If the server is re-published, you must Run on Server again to re-initialize the Universal Test Client, even if the Web browser is still open. You can also manually re-initialize the Universal Test Client by:

  1. Start the Universal Test Client.
  2. In the browser window opened to the Universal Test Client, click on JNDI properties. The JNDI properties page will now be displayed.
  3. In the Initial Factory field, type weblogic.jndi.WLInitialContextFactory.
  4. In the Provider URL field, type t3://localhost:7001/ (where 7001 is the HTTP port that you have configured WebLogic server to use). If you are using a remote server, replace localhost with the host name of the remote server.
  5. Click the Set button.

The feature to browse the JNDI tree in the Universal Test Client JNDI Explorer is not available when using a WebLogic server. Instead, you locate beans by looking up their home using their JNDI bindings. For more information on setting up JNDI bindings, see Working with the WebLogic extensions page.

For example, given an EJB module named Widget with a home object WidgetHome that is bound to the JNDI name ejb/com/ibm/test/WidgetHome:

  1. In the Universal Test Client, open the JNDI Explorer.
  2. On the JNDI Explorer page, in the JNDI Name field, type ejb/com/ibm/test/WidgetHome. If an object is bound to this JNDI name, the References pane will open, showing the WidgetHome object.

Note: It may not be possible to look up local interfaces in WebLogic Server 8.1 and 7.0 due to the way JNDI is implemented in WebLogic Server.

Related tasks
Working with the WebLogic extensions page

Terms of use | Feedback
(C) Copyright IBM Corporation 2002, 2004. All Rights Reserved.