TS 60 EnterpriseResources

Enterprise Resources Test Specification for

Author: Martin Schovanek
Version: 1.3
Last update: 2006/05/15
Introduction:
Comments:

Contents


Test suite: Enterprise Resources Suite

Purpose: This suite tests actions from Enterprise Resource menu.
Setup:

  • create/open a J2EE 1.4 EAR Project with a Session Bean and a Message Driven Bean
  • create a TestServlet class

Note: you can use preprepared EAR14Test project.

            
  1. Call Enterprise Bean
                   Chose  Enterprise Resources > Call Enterprise Bean  from the servlet's contextual menu.
               
    1. Chose a Enterprise Bean and generate call (look up) method.
    2. Use the call method in the TestServlet.
    3. Deploy the Enterprise Application and call the TestServlet.
    • EXPECTED RESULT: The TestServlet result is valid.
  1. Use Database
                   Chose  Enterprise Resources > Use Database  from the servlet's contextual menu.
               
                   Chose a Database Connection and let NetBeans to generate Data Source lookup method.
               
    1. Use the method in the TestServlet.
    2. Deploy the Enterprise Application and call the TestServlet.
    • EXPECTED RESULT: The TestServlet result is valid.
  1. Send E-Mail
                   Chose  Enterprise Resources > Send E-mail  from the servlet's contextual menu.
               
                   Enter a existing Mail Resource JNDI Name and let NetBeans to generate sendEmail() method.
               
    1. Use the method in the TestServlet.
    2. Deploy the Enterprise Application and call the TestServlet.
    • EXPECTED RESULT: The TestServlet sends valid email.
  1. Send JMS Message
                   Chose  Enterprise Resources > Send JMS Message  from the servlet's contextual menu.
               
    1. Chose a Message Driven Bean and generate sendJMSMessage...() method.
    2. Implement createJMSMessage...() method
    3. Use the sendJMSMessage...() method in the TestServlet.
    4. Deploy the Enterprise Application and call the TestServlet.
    • EXPECTED RESULT: JMS Message is sent.


Test suite: Enterprise Resources Suite for Java EE 5 project type

Purpose:

               This suite tests actions from Enterprise Resource menu in Java EE 5 project.
            

Setup:

  • unzip and open EAR5Test project
  • open EAR5Test-war > Source Packages > war > TestServlet.java
            
  1. Call EE5 Enterprise Bean
                   Chose  Enterprise Resources > Call Enterprise Bean  from the servlet's contextual menu.
               
    1. Chose a Enterprise Bean and generate call (look up) method.
                   Generate local calls for  TestSessionBean  and  CustomerFacade  beans.
               
    • EXPECTED RESULT: IDE generates @EJB annotated fields.
  1. Use EE5 Database
                   Chose  Enterprise Resources > Use Database  from the servlet's contextual menu.
               
    1. Chose jdbc/EE5Sample data source and generate Inline Lookup Code.
    • EXPECTED RESULT: IDE generates @Resource annotated DataSource field.
  1. Send EE5 E-Mail
                   Chose  Enterprise Resources > Send E-mail  from the servlet's contextual menu.
               
                   Enter  mail/TestSession  mail resource JNDI Name and generate Inline Lookup Code.
               
    • EXPECTED RESULT:
                   IDE generates @Resource annotated javax.mail.Session field and sendEmail(...) method.
 
  1. Send EE5 JMS Message
                   Chose  Enterprise Resources > Send JMS Message  from the servlet's contextual menu.
               
    1. Chose the TestEE5MessageDestination destination and generate Inline Lookup Code.
    2. Implement createJMSMessage...() method
    • {{{1}}}

Generated: Tue Dec 19 15:37:13 CET 2006

Not logged in. Log in, Register

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo