What does 'automating a use case 'means and how does the tools that automate helps with that? whats makes automation good to do and does it holds any significance for web developement.

  • What context are you seeing the phrase used?
    – Jay Elston
    Apr 9 '12 at 13:31
  • for a customer based web design i have to recomend a open-source tool that automates a use case and i have to justify my choice.
    – mu_sa
    Apr 9 '12 at 14:02

Suppose you have a form where users can make an account. Would you prefer to manually fill in 20 text boxes, tens of times with all kinds of input that may give wrong results? Or would you rather have an automatic test do that for you in a matter of seconds?

A use case by all means is some action or procedure that your application should support, for example "register". A use case is something that one or more "actors" can do, people who would be users of your application for example "site visitor".

An automated test for the use case "register" that a "site visitor" can do, would be to create various inputs for the different data, preferrably a mixture of valid and invalid ones, then create a test class that tries to use your program with these inputs, test whether the invalid ones are correctly detected and the valid ones are accepted by using assert statements, then view the test results.

Writing the test can take a lot of time, but the big advantage is that it should still work after you made changes to your application. If it doesn't, that means you have introduced a bug into your application.

The most interesting datatypes to test for are things like numbers and dates, where you should test for interval edges, if any apply.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.