Programming Tutorials Browser Tutorials Articles Struts Tutorials Hibernate Tutorials

  Tutorial: Testing JSPs with jWebUnit

Testing JSPs with jWebUnit jWebUnit is a Java framework that facilitates creation of acceptance tests for web applications. It evolved from a project where we were using HttpUnit and JUnit to create acceptance tests

Tutorial Details:

jWebUnit provides a high-level API for navigating a web application combined with a set of assertions to verify the application\'s correctness. This includes navigation via links, form entry and submission, validation of table contents, and other typical business web application features. This code utilizes HttpUnit behind the scenes. The simple navigation methods and ready-to-use assertions allow for more rapid test creation than using only JUnit and HttpUnit.

The following sample testcases illustrate the conciseness of jWebUnit versus HttpUnit and JUnit alone. The tests perform a google search for the HttpUnit home page, navigate to that page from Google, and validate that there is a link to the user manual on the HttpUnit home page. The code in the first column is pure HttpUnit / JUnit, while the second column uses the jWebUnit framework.


 

Read Tutorial at: Click here to view the tutorial

Rate Tutorial:
Testing JSPs with jWebUnit

View Tutorial:
Testing JSPs with jWebUnit

Related Tutorials:

JavaWorld Developer Tools Guide: Testing Tools
JavaWorld Developer Tools Guide: Testing Tools
 
Get the app out - JavaWorld January 2001
Get the app out - JavaWorld January 2001
 
JSP best practices
Follow these tips for reusable and easily maintainable JavaServer Pages
 
Step into the J2EE architecture and process
Step into the J2EE architecture and process
 
Rumble in the jungle: J2EE versus .Net, Part 1
Rumble in the jungle: J2EE versus .Net, Part 1
 
Rumble in the jungle: J2EE versus .Net, Part 2
Rumble in the jungle: J2EE versus .Net, Part 2
 
Business process automation made easy with Java, Part 1
Business process automation made easy with Java, Part 1
 
Java Testing and Design
Java Testing and Java Test and Design is the companion to any book on Java software development practices, techniques, and testing. Software developers, QA analysts and IT managers working in large corporate IT groups, software development companies, and
 
Software Testing Website - Eclipse JIRA Plugin
Software Testing Website - Eclipse JIRA Plugin The Eclipse JIRA Plugin Release 1.0.1 is now available. We have fixed a few minor bugs, many thanks to all who have helped with testing and debugging. You can download it here: Eclipse JIRA Plugin 1.0.
 
Martin Fowler\'s usual terrific writing
The term 'Mock Objects' has become a popular one to describe special case objects that mimic real objects for testing. However the term mock was not originally meant as a more catchy name for stub, but to introduce a different approach to unit testing. In
 
Testing J2EE applications
Testing J2EE applications There are certain aspects of J2EE applications that people associate with end-to-end tests rather than object tests. These include page flow—or navigating a Web application—and using container services, such as security and
 
JDemo: Interactive Testing Refactored
This article will introduce the JDemo framework and its techniques for writing code for interactive testing. It will also show the benefits that can be gained from writing demo code.
 
Automate GUI tests for Swing applications
Summary Automation is necessary for frequent and consistent testing, which is the foundation of agile development. However, acceptance tests of GUI applications are not always easy to automate. This article explains a simple way of automating Java Swing
 
Advanced form processing using JSP
Processing HTML forms using servlets, or more often, CGI scripts, is one of the most common operations performed on the Web today. However, that JavaServer Pages (JSPs) can play a significant role in sophisticated form processing is a little-known secret.
 
Building Java Server Pages
A detailed look at building JSP pages. Should you use JSP or servlets? It mainly depends on the ratio of markup to code. Here you'll also find a guide to the different varieties of tag, and details about the main tags such as and  
Tutorial for Developing your first JSPs tags
We have seen how servlets and JSPs can be used to build a web application. These technologies go some distance toward making web development easier, but do not yet facilitate the separation of Java from HTML in a reusable way. Custom tags make this possib
 
Compare JavaServer Pages: Tag Libraries vs. JavaBeans
Java provides developers with JavaServer Pages (JSPs) and Servlets as a superior alternative to traditional CGI programs. The architecture of JSPs provide support for a logical and physical separation between the HTML page designers and the component deve
 
This tutorial shows how to Combine the power of XPath and JSP tag libraries
In this article, we'll examine the XPath custom tag library for JSPs and see a tag collection that provides simple control constructs and a uniform attribute value substitution facility, all of which combine to reduce complexity and improve functionality.
 
Reuse Tiles and Simplify UI
JavaServer Pages (JSP) technology supports application object reuse through includes, which allow other files (including other JSPs) to be sourced into a JSP file either at compile time or dynamically at application runtime. This is great for abstracting
 
Using tiles-defs.xml in Tiles Application
Using tiles-defs.xml in Tiles Application Using tiles-defs.xml in Tiles Application In the last section we studied how to forward the request (call) to a jsp page which specifies which tiles layout definition should be used to apply to the
 
Site navigation
 

 

Send your comments, Suggestions or Queries regarding this site at roseindia_net@yahoo.com.

Copyright © 2006. All rights reserved.