cornercorner
FeaturesPluginsDocs & SupportCommunityPartners

J2EE - Wizards Test Specification

Author: Lukas Jungmann
Version: 1.0.0
Last update: 14.09.2005
Introduction: Test specification for New Project and New File Wizards in J2EE area. Tests are covered mainly by automated tests in J2EE functional test suite, see: NewProjectWizardsTest, NewFileWizardsTest and J2eeProjectsTest.
Comment:

Table of Contents

Test suite 1: New EJB Module wizard

Purpose: Specifies behavior of New Project Wizard for EJB Module project.
Setup: Registered application server in IDE. Currently it can be Sun Java Application Server 8.1, JBoss 4.x or Weblogic 9.0.

#Test caseDescription
1Choose Project Type: EJB Module
  1. Invoke File | New Project...
  2. Select Enterprise category and EJB Module project type, click Next
RESULT:Appearance of New EJB Mdule wizard panel (step 2 of New Project wizard).
2Project Name, Location, Server,...
  1. Enter the name of new project into Project Name.
  2. Project Location allows to select location of created project (user can use Browse... button).
  3. Project Folder shows new project's path
  4. Server list allows user to choose target application server for this project.
  5. J2EE Version allows user to choose J2EE version which will be used in this project (currently only 1.4 is possible to use).
  6. Set Source Level to 1.4 checkbox allows user to choose J2SE version used by this project. Checked by default to create portability code.
  7. Set as Main Project checkbox allows user to set this project "as default" for build (F11), run (F5), debug (F6) and clean (Shift + F11) commands.
  8. Back button should invoke Choose Project Type panel. Here you can choose different project type.
  9. Cancel should close this dialog
  10. The Help button serves to invoke help.
RESULT:Finish button becomes enabled if there is selected some application server and if valid values for Project Name (it does not contain invalid characters, it is not existing directory within selected project location) and Project Location (it is existing directory and user has write access to it) are used.
3Add to Enterprise application
  1. Add to Enterprise Application list allows user to add newly created project to some existing Enterprise Application project. This Enterprise Application have to be opened in the IDE. If there's no such project opened then this list is disabled.
  2. Press Finish button.
RESULT:EJB Module project is created in selected location wth properties selected in the wizard. Check: Source Level in Project Properties -> Sources | Source Level, Server and J2EE version in Project Properties -> Run | Server, Main Project - project name in project tab is displayed bold and deployment descriptors (ejb-jar.xml and server specific one) are created in the src/conf directory in the project.

Test suite 2: New Enterprise Application wizard

Purpose: Specifies behavior of New Project Wizard for Enterprise Application project.
Setup: Registered application server in IDE. Currently it can be Sun Java Application Server 8.1, JBoss 4.x or Weblogic 9.0.

#Test caseDescription
1Choose Project Type: Enterprise Application
  1. Invoke File | New Project...
  2. Select Enterprise category and Enterprise Application project type, click Next
RESULT:Appearance of New Enterprise Application wizard panel (step 2 of New Project wizard).
2Project Name, Location, Server,...
  1. Enter the name of new project into Project Name.
  2. Project Location allows to select location of created project (user can use Browse... button).
  3. Project Folder shows new project's path
  4. Server list allows user to choose target application server for this project.
  5. J2EE Version allows user to choose J2EE version which will be used in this project (currently only 1.4 is possible to use).
  6. Set Source Level to 1.4 checkbox allows user to choose J2SE version used by this project. Checked by default to create portability code.
  7. Set as Main Project checkbox allows user to set this project "as default" for build (F11), run (F5), debug (F6) and clean (Shift + F11) commands.
  8. Back button should invoke Choose Project Type panel. Here you can choose different project type.
  9. Cancel should close this dialog
  10. The Help button serves to invoke help.
RESULT:Finish button becomes enabled if there is selected some application server and if valid values for Project Name (it does not contain invalid characters, it is not existing directory within selected project location) and Project Location (it is existing directory and user has write access to it) are used.
3Create submodules
  1. Create EJB Module checkbox allows user to create new empty EJB module project within this Enterprise Application. It will be created using default values in subdirectory of this ear and it will use the Source Level setting selected in this wizard.
  2. Create Web Application Module checkbox allows user to create new empty Web Application project within this Enterprise Application. It will be created using default values in subdirectory of this ear and it will use the Source Level setting selected in this wizard.
  3. Press Finish button.
RESULT:Enterprise Application project is created in selected location wth properties selected in the wizard. Check: Source Level in Project Properties -> Sources | Source Level, Server and J2EE version in Project Properties -> Run | Server, Main Project - project name in project tab is displayed bold and deployment descriptors (application.xml and server specific one) are created in the src/conf directory in the project. If options for creating ejb/web module were checked then these projects are created too, they are visible in project tab under <ear> | J2EE Modules node in project tab and all projects are opened in IDE.

Test suite 3: New Session Bean wizard

Purpose: Specifies behavior of New File Wizard for Session Bean.
Setup: Opened or created EJB Module project.

#Test caseDescription
1Choose File Type: Session Bean
  1. Use popup New (select some package in Project view, show popup menu and invoke action New | File/Folder...) or invoke main menu File|New File....
  2. Select Enterprise in Categories tree and select Session Bean in File Types list.
  3. Push Next button.
RESULT:Appearance of New Session Bean wizard panel (step 2 of New File wizard).
2Choose Name & Package
  1. Name text field allows user to write name of the created component.
  2. Package list allows to select new class'es package.
RESULT:If name is not valid java identifier or package name is not valid java package name, then Finish button will not become enabled.
3Session Type
  1. Session Type radio buttons (stateless, stateful) allows user to choose the type of the bean.
RESULT:Created bean will be stateless/stateful as was selected. Check it in deployment descriptor.
4Interfaces
  1. Create Interface checkboxes allows user to select which types of interfaces will be created. At least one of the checkboxes have to be checked.
RESULT:If none of checkboxes is selected then the Finish button in the wizard is disabled. Otherwise Finish button is enabled.
5Finish
  1. Finish the wizard.
RESULT:Stateless/Stateful bean with specified name, local, remote or both interfaces is created in specified package, deployment descriptors are changed and bean impl class is opened in editor window

Test suite 4: New Entity Bean wizard

Purpose: Specifies behavior of New File Wizard for Entity Bean.
Setup: Opened or created EJB Module project.

#Test caseDescription
1Choose File Type: Entity Bean
  1. Use popup New (select some package in Project view, show popup menu and invoke action New | File/Folder...) or invoke main menu File|New File....
  2. Select Enterprise in Categories tree and select Entity Bean in File Types list.
  3. Push Next button.
RESULT:Appearance of New Entity Bean wizard panel (step 2 of New File wizard).
2Choose Name & Package
  1. Name text field allows user to write name of the created component.
  2. Package list allows to select new class'es package.
RESULT:If name is not valid java identifier or package name is not valid java package name, then Finish button will not become enabled.
3Entity Type
  1. Primary Key Class contains the type of primary key for this bean. Must not be empty.
  2. Persistence Type radio buttons (container, bean) allows user to choose which the type of the persistence will be used.
RESULT:Created bean will use container/bean managed persistence as was selected and with selected primary key class. Check it in deployment descriptor and in generated classes.
4Interfaces
  1. Create Interface checkboxes allows user to select which types of interfaces will be created. At least one of the checkboxes have to be checked.
RESULT:If none of checkboxes is selected then the Finish button in the wizard is disabled. Otherwise Finish button is enabled.
5Finish
  1. Finish the wizard.
RESULT:CMP/BMP bean with specified name, local, remote or both interfaces is created in specified package, deployment descriptors are changed and bean impl class is opened in editor window.

Test suite 5: New Message-Driven Bean wizard

Purpose: Specifies behavior of New File Wizard for Message-Driven Bean.
Setup: Opened or created EJB Module project.

#Test caseDescription
1Choose File Type: Message-Driven Bean
  1. Use popup New (select some package in Project view, show popup menu and invoke action New | File/Folder...) or invoke main menu File|New File....
  2. Select Enterprise in Categories tree and select Message-Driven Bean in File Types list.
  3. Push Next button.
RESULT:Appearance of New Message-Driven Bean wizard panel (step 2 of New File wizard).
2Choose Name & Package
  1. Name text field allows user to write name of the created component.
  2. Package list allows to select new class'es package.
RESULT:If name is not valid java identifier or package name is not valid java package name, then Finish button will not become enabled.
3Message-Driven Type
  1. Destination Type radio buttons (topic, queue) allows user to choose the type of destination for messages.
RESULT:Created bean will use topic/queue destination as was selected. Check it in deployment descriptor.
4Finish
  1. Finish the wizard.
RESULT:Topic/Queue MDB with specified name is created in specified package, server resources are created setup directory, deployment descriptors are changed and bean impl class is opened in editor window.

Test suite 6: New Service Locator wizard

Purpose: Specifies behavior of New File Wizard for Service Locator.
Setup: Opened or created EJB Module project, Web project or J2SE project.

#Test caseDescription
1Choose File Type: Service Locator
  1. Use popup New (select some package in Project view, show popup menu and invoke action New | File/Folder...) or invoke main menu File|New File....
  2. Select Enterprise in Categories tree and select Service Locator in File Types list.
  3. Push Next button.
RESULT:Appearance of New Service Locator wizard panel (step 2 of New File wizard).
2Class File Name
  1. Enter the name of new object into $FILE_TYPE Name.
  2. Project field shows new class project's name.
  3. Location list allows to select location of created file in project.
  4. Package list allows to select new class'es package
  5. Created File shows new file's path
  6. Back button should invoke Choose File Type panel. Here you can choose different file type.
  7. Cancel should close this dialog
  8. The Help button serves to invoke help.
  9. The Finish button creates class from template. This page should check, if the class name is correct.
  10. Press Finish button.
RESULT:New file is created into specified package of selected project and opened in editor window.

Test suite 7: New Caching Service Locator wizard

Purpose: Specifies behavior of New File Wizard for Caching Service Locator.
Setup: Opened or created EJB Module project, Web project or J2SE project.

#Test caseDescription
1Choose File Type: Caching Service Locator
  1. Use popup New (select some package in Project view, show popup menu and invoke action New | File/Folder...) or invoke main menu File|New File....
  2. Select Enterprise in Categories tree and select Caching Service Locator in File Types list.
  3. Push Next button.
RESULT:Appearance of New Caching Service Locator wizard panel (step 2 of New File wizard).
2Class File Name
  1. Enter the name of new object into $FILE_TYPE Name.
  2. Project field shows new class project's name.
  3. Location list allows to select location of created file in project.
  4. Package list allows to select new class'es package
  5. Created File shows new file's path
  6. Back button should invoke Choose File Type panel. Here you can choose different file type.
  7. Cancel should close this dialog
  8. The Help button serves to invoke help.
  9. The Finish button creates class from template. This page should check, if the class name is correct.
  10. Press Finish button.
RESULT:New file is created into specified package of selected project and opened in editor window.

Test suite 8: New Web Service wizard

Purpose: Specifies behavior of New File Wizard for Web Service.
Setup: Opened or created EJB Module project or Web project.

#Test caseDescription
1Choose File Type: Web Service
  1. Use popup New (select some package in Project view, show popup menu and invoke action New | File/Folder...) or invoke main menu File|New File....
  2. Select Web Services in Categories tree and select Web Service in File Types list.
  3. Push Next button.
RESULT:Appearance of New Web Service wizard panel (step 2 of New File wizard).
2Choose Name & Package
  1. Name text field allows user to write name of the created component.
  2. Package list allows to select new class'es package.
RESULT:If name is not valid java identifier or package name is not valid java package name, then Finish button will not become enabled.
3From scratch
  1. Choose From scratch in Web Service Creation Type.
  2. Push Finish button.
RESULT:Empty Web service interface and implementation bean, webservices.xml and webservice mapping file are created, deployment descriptors are changed. Web service implementation class is opened in editor window.

Test suite 9: New Web Service wizard (existing sources)

Purpose: Specifies behavior of New File Wizard for Web Service.
Setup: Opened or created EJB Module project or Web project.

#Test caseDescription
1Choose File Type: Web Service
  1. Use popup New (select some package in Project view, show popup menu and invoke action New | File/Folder...) or invoke main menu File|New File....
  2. Select Web Services in Categories tree and select Web Service in File Types list.
  3. Push Next button.
RESULT:Appearance of New Web Service wizard panel (step 2 of New File wizard).
2Choose Name & Package
  1. Name text field allows user to write name of the created component.
  2. Package list allows to select new class'es package.
RESULT:If name is not valid java identifier or package name is not valid java package name, then Finish button will not become enabled.
3From existing sources
  1. Choose From scratch in Web Service Creation Type and check Use existing code checkbox.
  2. Push Next button.
RESULT:Appearance of Select Existing Code wizard panel (step 3 of New Project wizard).
4Select existing sources
  1. Choose class/interface/session bean which you want to use as a base for your new web service.
  2. Push Finish button.
RESULT:Empty web service interface, web service implementation class with package private property of type of selected class/interface/session bean, webservices.xml and web service mapping file are created, deployment descriptors are changed. Web service implementation class is opened in editor window.

Test suite 10: New Web Service wizard (wsdl url)

Purpose: Specifies behavior of New File Wizard for Web Service.
Setup: Opened or created EJB Module project or Web project. Optional: If you are behind the proxy server, set proxy in Tools | Options.

#Test caseDescription
1Choose File Type: Web Service
  1. Use popup New (select some package in Project view, show popup menu and invoke action New | File/Folder...) or invoke main menu File|New File....
  2. Select Web Services in Categories tree and select Web Service in File Types list.
  3. Push Next button.
RESULT:Appearance of New Web Service wizard panel (step 2 of New File wizard).
2Choose Name & Package
  1. Name text field allows user to write name of the created component.
  2. Package list allows to select new class'es package.
RESULT:If name is not valid java identifier or package name is not valid java package name, then Finish button will not become enabled.
3From WSDL URL
  1. Choose From WSDL URL in Web Service Creation Type and write URL location of WSDL file you want use.
  2. Push Finish button.
RESULT:Web service interface and web service implementation class contain operation(s) defined in WSDL file, WSDL file is downloaded and web service mapping file and webservices.xml files are created, deployment descriptors are changed. Web service implementation class is opened in editor window.

Test suite 11: New Web Service wizard (local wsdl file)

Purpose: Specifies behavior of New File Wizard for Web Service.
Setup: Opened or created EJB Module project or Web project.

#Test caseDescription
1Choose File Type: Web Service
  1. Use popup New (select some package in Project view, show popup menu and invoke action New | File/Folder...) or invoke main menu File|New File....
  2. Select Web Services in Categories tree and select Web Service in File Types list.
  3. Push Next button.
RESULT:Appearance of New Web Service wizard panel (step 2 of New File wizard).
2Choose Name & Package
  1. Name text field allows user to write name of the created component.
  2. Package list allows to select new class'es package.
RESULT:If name is not valid java identifier or package name is not valid java package name, then Finish button will not become enabled.
3From local WSDL
  1. Choose From Local WSDL file in Web Service Creation Type and select some wsdl file from your disk (you can use Browse... button).
  2. Push Finish button.
RESULT:Web service interface and web service implementation class contain operation(s) defined in WSDL file, WSDL file is downloaded and web service mapping file and webservices.xml files are created, deployment descriptors are changed. Web service implementation class is opened in editor window.

Test suite 12: New Web Service Client wizard

Purpose: Specifies behavior of New File Wizard for Web Service Client.
Setup: Opened or created Web project or J2SE project.

#Test caseDescription
1Choose File Type: Web Service Client
  1. Use popup New (select some package in Project view, show popup menu and invoke action New | File/Folder...) or invoke main menu File|New File....
  2. Select Web Services in Categories tree and select Web Service Client in File Types list.
  3. Push Next button.
RESULT:Appearance of New Web Service Client wizard panel (step 2 of New File wizard).
2Select options
  1. WSDL URL text field allows user to write there URL of running web service. This text filed is enabled if user selects creating web service client for running web service.
  2. Retrive WSDL button allows user to download WSDL file. This button is enabled if user is creating web service client for running web service.
  3. Proxy Settings... button allows user to set the proxy server. This button is enabled if user is creating web service client for running web service.
  4. Local Filename text field allows user to change the name of downloaded wsdl file. This text filed is enabled if user is creating web service client for running web service.
  5. WSDL Filename text field allows user to use local wsdl file (user can use Browse... button). This text filed is enabled if user is creating web service client for web service from existing WSDL file.
  6. Package list allows to select new class'es package.
  7. Client Type combox allows user to choose which type of client generate.
  8. Back button should invoke Choose File Type panel. Here you can choose different file type.
  9. Cancel should close this dialog
  10. The Help button serves to invoke help.
  11. The Finish button generated web service client. This page should check, if the package name is correct and wsdl is downloaded.
  12. Press Finish button.
RESULT:Web service client is generated, added to web service registry and is visible under Web Service references node in project view.

Test suite 13: New Message Handler wizard

Purpose: Specifies behavior of New File Wizard for Message Handler.
Setup: Opened or created EJB Module project, Web project or J2SE project.

#Test caseDescription
1Choose File Type: Message Handler
  1. Use popup New (select some package in Project view, show popup menu and invoke action New | File/Folder...) or invoke main menu File|New File....
  2. Select Web Services in Categories tree and select Message Handler in File Types list.
  3. Push Next button.
RESULT:Appearance of New Message Handler wizard panel (step 2 of New File wizard).
2Class File Name
  1. Enter the name of new object into $FILE_TYPE Name.
  2. Project field shows new class project's name.
  3. Location list allows to select location of created file in project.
  4. Package list allows to select new class'es package
  5. Created File shows new file's path
  6. Back button should invoke Choose File Type panel. Here you can choose different file type.
  7. Cancel should close this dialog
  8. The Help button serves to invoke help.
  9. The Finish button creates class from template. This page should check, if the class name is correct.
  10. Press Finish button.
RESULT:New file is created into specified package of selected project and opened in editor window.

Test suite 14: New WSDL File wizard

Purpose: Specifies behavior of New File Wizard for WSDL File.
Setup: Opened or created EJB Module project, Web project or J2SE project.

#Test caseDescription
1Choose File Type: WSDL File
  1. Use popup New (select some package in Project view, show popup menu and invoke action New | File/Folder...) or invoke main menu File|New File....
  2. Select Web Services in Categories tree and select WSDL File in File Types list.
  3. Push Next button.
RESULT:Appearance of New WSDL File wizard panel (step 2 of New File wizard).
2WSDL File Name
  1. Enter the name of new WSDL file into File Name.
  2. Project field shows new WSDL project's name.
  3. Folder allows to select location of created file in project (you can use Browse... button)
  4. Created File shows new WSDL file's path
  5. Service Name allows to type name of web service defined by this WSDL file
  6. Target Namespace allows to define target namespace for web service defined by this WSDL
  7. Back button should invoke Choose File Type panel. Here you can choose different file type.
  8. Cancel should close this dialog
  9. The Help button serves to invoke help
  10. The Finish button creates WSDL file from template. This page should check, if the name is correct.
  11. Press Finish button.
RESULT:New file is created into specified folder of selected project and opened in editor window.

Generated: 2005 09 14 10:48
Companion
Projects:
MySQL Database Server   GlassFish Community: an Open Source Application Server   Open Solaris  Open JDK: an Open SourceJDK   Mobile & Embedded Community     Sponsored by 
Sponsored by Sun Microsystems