Browse Prior Art Database

An Extensible Application for Java Object Testing

IP.com Disclosure Number: IPCOM000014987D
Original Publication Date: 2001-Jun-17
Included in the Prior Art Database: 2003-Jun-20
Document File: 5 page(s) / 138K

Publishing Venue

IBM

Abstract

The Test Client in VisualAge for Java is a tool that lets you instantiate and test Java classes independently of the application the classes reside within. Once instantiated, users can view the methods and properties of the classes, modify them dynamically, and execute them. The value of this product to customers is that this product lets them test their Java code early in the development cycle before extensive coding of an application. With early testing, customers can study the behavior of the classes and test how that behavior is affected by a range of input data. Customers can confirm that the data returned by the classes at run time is what was expected, and the classes can handle a number of error conditions. The Test Client was designed to test Enterprise Java Beans (EJBs). An EJB is a special kind of Java bean that contains functions used by web-based applications running on an application server. Since EJBs themselves are non-visual, developers usually need to write the user interface in order to test the EJB functions. But the Test Client lets you test the EJBs without any user interface. Essentially, it is a substitute user interface. The Test Client also has an Enterprise Access Builder (EAB) version. In this version, applications using connectors can be tested without developing a user interface. The value of the Test Client is that you can test your code early in the development cycle. Function 1: Launching a Class for Examination Test Client Very easy. Right-click on the class in the Integrated Development Environment (IDE). From the pop-up menu, click Tools Enterprise Access Builder Launch Test Client . Function 2: Constructing a New Object Using an Existing Constructor (new(...)) Test Client When classes are instantiated they become objects. The new operator creates an object using the constructor it finds in the class. Creating objects and modifying them is a central concept in the Test Client. It in affect lets a user play around with a few variations on an idea. The Test Client

This text was extracted from a PDF file.
At least one non-text object (such as an image or picture) has been suppressed.
This is the abbreviated version, containing approximately 41% of the total text.

Page 1 of 5

An Extensible Application for Java Object Testing

The Test Client in VisualAge for Java is a tool that lets you instantiate and test Java classes independently of the application the classes reside within. Once instantiated, users can view the methods and properties of the classes, modify them dynamically, and execute them. The value of this product to customers is that this product lets them test their Java code early in the development cycle before extensive coding of an application. With early testing, customers can study the behavior of the classes and test how that behavior is affected by a range of input data. Customers can confirm that the data returned by the classes at run time is what was expected, and the classes can handle a number of error conditions.

The Test Client was designed to test Enterprise Java Beans (EJBs). An EJB is a special kind of Java bean that contains functions used by web-based applications running on an application server. Since EJBs themselves are non-visual, developers usually need to write the user interface in order to test the EJB functions. But the Test Client lets you test the EJBs without any user interface. Essentially, it is a substitute user interface. The Test Client also has an Enterprise Access Builder (EAB) version. In this version, applications using connectors can be tested without developing a user interface. The value of the Test Client is that you can test your code early in the development cycle.

Function 1: Launching a Class for Examination - Test Client Very easy. Right-click on the class in the Integrated Development Environment (IDE). From the pop-up menu, click Tools > Enterprise Access Builder > Launch Test Client.

Function 2: Constructing a New Object Using an Existing Constructor (new(...)) - Test Client When classes are instantiated they become objects. The new operator creates an object using the constructor it finds in the class. Creating objects and modifying them is a central concept in the Test Client. It in affect lets a user play around with a few variations on an idea. The Test Client

1

[This page contains 1 picture or other non-text object]

Page 2 of 5

lets you quickly create these objects for experimentation. Simply right-click on the class and select new(...) from the pop-up menu. A Constructors window opens and you can invoke that constructor; that is, create an object. The details of the object are shown and the instances of the object are listed because you can create several of them.

Function 3: Constructing a New Object with the Default Constructor (new()) - Test Client This function is similar to the previous one but calls the default constructor. The default constructor has no arguments and it is used when no constructor has been defined. With the Test Client, you select new() instead of new(...).

Function 4: Assign Null - Test Client This function lets you set an object to null. It is handy when you're testing for the possibility of no input being pas...