Transwiki:Common Test Cases

The purpose of this page is to help suggest some possible test cases you should be running for different types of things one might test. =Purpose= The purpose of this page is to get QA engineers thinking out of the box when it comes to testing different permutations of data. This site does not tell you how the system you are testing should react to this data, but is just a suggestion of the type of data you should try to use for testing. Please feel free to add your own permutations to this site. =Data Types=

String

 * Min- (1 less character than the allowable minimum)
 * Min (minimum allowable # of characters)
 * Max (maximum allowable # of characters)
 * Max+ (1 more character than the allowable maximum)
 * Null ("null")
 * Empty ("")
 * Space (" ")
 * Leading Spaces ("  abc")
 * Trailing Spaces ("abc  ")
 * Spaces in the middle ("abc def")
 * Case Sensitivity ("McLane")
 * Non-alphabetical characters ("abc123")
 * Special characters ("`~!@#$%^&*_+{}|:"<>?[]\;',./") Note: There are 32 of these
 * Special characters in the middle ("McLane-Smith" or "Smith,Anne")
 * Extended characters (èü)
 * International characters (asian, bi-directional)

Integer

 * Min- (1 less than the allowable minimum #)
 * Min (minimum allowable #)
 * Max (maximum allowable #)
 * Max+ (1 more character than the allowable maximum --if you are allowed any size Integer, then you may want to test with a bigger data type)
 * Null ("null")
 * Empty ("")
 * Space (" ")
 * Leading Spaces ("  123")
 * Trailing Spaces ("123  ")
 * Spaces in the middle ("123 456")
 * Non-numeric characters ("abc123")
 * Special characters ("`~!@#$%^&*_+{}|:"<>?[]\;',./") Note: There are 32 of these
 * Special characters in the middle ("123-456-7890")
 * Leading with Zeros ("000123")
 * Trailing with Zeros ("123000")

Double/Float

 * Min- (1 less than the allowable minimum #)
 * Min (minimum allowable #)
 * Max (maximum allowable #)
 * Max+ (1 more character than the allowable maximum --if you are allowed any size double/float, then you may want to test with a bigger data type)
 * Null ("null")
 * Empty ("")
 * Space (" ")
 * Leading Spaces ("  123.84")
 * Trailing Spaces ("123.08  ")
 * Spaces in the middle ("123 456.85")
 * Non-numeric characters ("abc123.04")
 * Special characters ("`~!@#$%^&*_+{}|:"<>?[]\;',./") Note: There are 32 of these
 * Special characters in the middle ("123.94-456")
 * Leading with Zeros ("000123.5700")
 * Trailing with Zeros
 * With #'s after decimal ("123000.3400")
 * Without #'s after decimal ("123000.0000")
 * Localization
 * Comma verses decimal (10,000 verses 10.000)
 * Characters that represent Floating or Doubles
 * Float (10.00F, 10.00f)
 * Double (10.00D, 10.00d)

Objects

 * Null
 * Valid Object
 * Object that can be cast to the correct type of object
 * Example: API takes object Cat, I should pass in object Animal
 * Foo ([CAT]Animal)
 * Example: Api takes object Animal, I should pass in object Cat since it inherited from Animal
 * Foo2 (Cat)

Dates

 * Test All Months
 * Test all days of the week
 * Test the first date of each month
 * Test the last day of each month
 * Test days that never exist
 * February 30
 * Leap Year
 * February 29
 * Formatting
 * YY-MM-DD
 * YYYY-MM-DD
 * DD-MM-YY
 * MM-DD-YYYY
 * MM/DD/YY
 * Many others, see your languages date formatting options
 * Note: Different Databases have different formatting for dates
 * Leading/Trailing Zeros
 * 08-01-07
 * 10-30-2010
 * Numerical representation of Months
 * Try each # (1-12)
 * Try 0
 * Try 13
 * Gotchas
 * In Java, the Month is zero-indexed. This means if you pass in 5 (May), it could be interpreted as 6 (June).  This is particarly important for dates that are going to be compared.

Times

 * AM
 * 12:00 AM
 * 1:10 AM
 * PM
 * 12:00 PM
 * 1:05 PM
 * 24 Hours
 * 00:15 (12:15 am)
 * 03:10 (3:10 am)
 * 13:00 (1:00 pm)
 * 24:00 (12:00 am)
 * 23:55 (11:55 pm)
 * 24 Hours (without colons, military time)
 * 1300 (1:00 pm)
 * 0600 (6:00 am)
 * Midnight on 24 Hour scale
 * 00:00 (12:00am)
 * Start with 0
 * 01:15 AM
 * 00:04 PM
 * End with 0
 * 10:40 AM
 * 11:00 PM
 * Time Zones
 * GMT
 * PST
 * Etc (http://aa.usno.navy.mil/faq/docs/world_tzones.html)
 * GMT Offset
 * 16:40 -0800 (4:40pm PST PST standard time)
 * 08:38 -0700 (8:38am PST PDT daylight savings)
 * Daylight Saving Time
 * Fall Back
 * Spring Forward
 * Information Regarding exact Dates of DST

Date/Time Permutations

 * End of Month/End of Day
 * Start of Month/Start of Day
 * End of Year/End of Day
 * Start of year/Start of day
 * Also see Date & Time Sections of wiki

Arrays

 * Min (Index starts at 0)
 * Max
 * Max+ (index out of bounds)
 * Try different types of data based on the elements allowed in that array
 * Example: Array[INT] can only contains ints
 * Example: Array[Animals] could have cat, dog, fish, etc

=People Info=

Address Line

 * Regular
 * Max Length for Address
 * Multiple Address Lines (2, 3, 4)
 * Half addresses
 * 115 1/2 Main Ave.
 * Streets with Numbers
 * 194 5th Street
 * 194 Fifth Street
 * With PO Box
 * With Rural Route
 * With Suite/Apt
 * With Mail Stop/Floor
 * Spaces
 * Special Chars
 * Abbreviations
 * Street (St.)
 * Avenue (Ave.)
 * Road (Rd.)
 * Mountain (Mt.)
 * Mountain (Mtn.)
 * Place (Pl.)
 * Way (Wy.)
 * Circle (Cir.)
 * Court (Ct.)
 * Saint (St.)
 * North (N.)
 * South (S.)
 * West (W.)
 * East (E.)
 * Many Other Examples: http://www.usps.com/ncsc/lookups/abbreviations.html#suffix

City

 * Valid Cities
 * San Diego
 * Dallas
 * Portland
 * Invalid Cities
 * Wahooooo
 * Cities with 2 words in the Name
 * San Jose
 * San Diego
 * Cities with spaces
 * Leading spaces
 * "  San Diego"
 * Middle Spaces
 * "San    Diego"
 * Trailing spaces
 * "San Diego  "
 * Cities with Abbreviations
 * St. Louis
 * St. Paul & Saint Paul
 * One city from each state
 * Montgomery, AL
 * Juneau,AK
 * Phoenix,AZ
 * Little Rock, AR
 * Sacramento,CA
 * Denver,CO
 * Hartford,CT
 * Dover,DE
 * Tallahassee,FL
 * Atlanta,GA
 * Honolulu,HI
 * Boise,ID
 * Springfield,IL
 * Indianapolis,IN
 * Des Moines,IA
 * Topeka,KS
 * Frankfort,KY
 * Baton Rouge,LA
 * Augusta,ME
 * Annapolis,MD
 * Boston,MA
 * Lansing,MI
 * St. Paul,MN
 * Jackson,MS
 * Jefferson City,MO
 * Helena,MT
 * Lincoln,NE
 * Carson City,NV
 * Concord,NH
 * Trenton,NJ
 * Santa Fe,NM
 * Albany,NY
 * Raleigh,NC
 * Bismarck,ND
 * Columbus,OH
 * Oklahoma City,OK
 * Salem,OR
 * Harrisburg,PA
 * Providence,RI
 * Columbia,SC
 * Pierre,SD
 * Nashville,TN
 * Austin,TX
 * Salt Lake City,UT
 * Montpelier,VT
 * Richmond,VA
 * Olympia,WA
 * Charleston,WV
 * Madison,WI
 * Cheyenne,WY
 * City with multiple zip codes
 * Bloomington, IN (zip codes for these are: 47403, 47407)
 * Cities that exist in more than 1 state
 * Kansas City MO and Kansas City KS (more or less one big city)
 * Miami FL and Miami OK (distant, unrelated cities)
 * TODO
 * City with an apostrophe
 * Land O' Lakes, FL
 * City with hyphen
 * Lauderdale-by-the-Sea, FL
 * City with mixed casing
 * McFarland, WI
 * Reference to Some Cities

State

 * Full name state
 * California
 * State with Spaces in Name
 * New York
 * North Carolina
 * Abbreviation
 * CA
 * NY
 * Invalid State Names
 * New Land
 * Calibornia
 * Test with all 50 states
 * Test with US Territories
 * Puerto Rico
 * Guam
 * US Virgin Islands
 * Samoa
 * Northern Marianas

Zip

 * Valid 5 digit zips
 * 33023 (HOLLYWOOD, FL)
 * 92126 (SAN DIEGO, CA)
 * APO/FPO zip codes
 * 09003
 * 09012
 * Invalid zips
 * 99999
 * 99999-9999
 * 99999 9999
 * 999999999
 * Spacing
 * leading spaces
 * " 92126"
 * Trailing spaces
 * "92126 "
 * Placement of zeros
 * Valid Zip with leading zeros
 * 03911 (YORK HARBOR, ME)
 * Valid Zip with trailing zeros
 * 49120 (NILES, MI)
 * 92126-1010 (SAN DIEGO, CA)
 * Valid 9 digit zip
 * No space/special char
 * 921261010 (SAN DIEGO, CA)
 * spaces
 * single spaces
 * "92126 1010" (SAN DIEGO, CA)
 * multiple spaces
 * "92126 1010" (SAN DIEGO, CA)
 * special char (-, hyphen)
 * hyphen with no spaces
 * 92126-1010 (SAN DIEGO, CA)
 * Hyphen with spaces
 * 92126 -1010 (SAN DIEGO, CA)
 * 92126 - 1010 (SAN DIEGO, CA)

Location (city/state/zip combos)

 * Valid City,State,Zip combo
 * San Diego,CA 92126
 * Mismatched City/State/Zip combos
 * Mismatch the city with the state & Zip
 * Orlando, CA 92126 (This is really San Diego)
 * Mismatch the state with the City & Zip
 * San Diego, TX 92126 (This is really CA)
 * Mismatch the Zip with the City & State
 * San Diego, CA 29822 (This is really 92126)
 * Mismatch all 3
 * Dallas, CA 29822
 * Spacing and Commas
 * Spaces
 * "San Diego CA 92126"
 * Multiple Spaces
 * "San Diego  CA   92126"
 * Comma
 * "San Diego,CA,92126
 * Multiple Commas
 * "San Diego,,CA,,92126"
 * Spaces & Commas
 * "San Diego, CA 92126"
 * Special Char in between
 * "San Diego#CA#92126"
 * Test all the other keyboard special chars
 * Furthwest point N, W, S, and E for the US
 * Furtherest Northern Point
 * Stevenson St, Barrow, AK
 * Furtherest Southern Point
 * 700 Windsor Lane, Key West, FL, 33040-6415
 * Furtherest Western Point
 * 1613 Pee Rd, Koloa, HI 96756
 * Furtherest Eastern Point
 * 96 Main St,Lubec, ME 04652

Phone

 * Area Code
 * No Area Code
 * 555-1212
 * With Valid Area Code
 * 858-555-1212
 * With Invalid Area Code
 * 999-555-1212
 * With Country Code
 * TODO
 * With Special Chars
 * 858#555#1212
 * Formatting
 * With Spaces
 * 858 555 1212
 * With Extension
 * 858-555-1212x123
 * Leading Spaces
 * " 858-555-1212"
 * Trailing Spaces
 * "858-555-1212 "
 * Alpha-Numeric
 * 5A5-1212
 * of Digits
 * Missing Digits
 * 55-1212
 * 555-121
 * Extra Digits
 * 5555-1212
 * 555-12121
 * 858-555-12121
 * 8581-555-1212
 * 858-5555-1212
 * Starting with 0
 * 095-1112
 * Starting with 1
 * 1-858-555-1212

Email Address

 * See also: email validation


 * Without @
 * Lindablah.com
 * Without com
 * Linda@blah.
 * Without period (.)
 * Linda@blahcom
 * Without Name
 * @blah.com
 * Without blah
 * Linda@.com
 * Invalid special chars
 * Linda!@#$%^&*+~`=[]\;',/{}|:"<>?.com
 * Valid Special Chars
 * TODO: Need to verify these
 * Hyphen (-)
 * linda-smith@yahoo.com
 * plus sign (+)
 * linda+smith@yahoo.com
 * Underscore (_)
 * linda_smith@yahoo.com
 * Minimum Length
 * Maximum Length
 * Different domains
 * edu (Example: lsmith@ucsd.edu)
 * au (Example: testbunny@100acreswoods.au)
 * org (Example: testbunny@100acreswoods.org)
 * ca (Example: testbunny@100acreswoods.ca)
 * net (Example: testbunny@100acreswoods.net)
 * com (Example: testbunny@100acreswoods.com)
 * gov (Example: testbunny@100acreswoods.gov)

Web URL

 * URL
 * www.blah.com
 * http://www.blah.com
 * URL with no www
 * blah.com
 * http://blah.com
 * URL with subdomain
 * home.blah.com
 * http://home.blah.com
 * URL with multiple subdomains
 * test.blahcentral.blah.com
 * http://test.blahcentral.blah.com
 * URL with SSL/https
 * https://home.blah.com
 * Without http
 * www.blah.com
 * Other Protocols
 * FTP
 * ftp://www.blah.com
 * Malformed URL's
 * //www.blah.com
 * http:www.blah.com
 * http:/www.blah.com
 * http://www.blah
 * http://www.blah.
 * http://www. .com (TODO: Find Ignore command for wiki)
 * URL's with different endings
 * http://www.blah.org
 * http://www.blah.au
 * http://www.blah.uk
 * http://www.ucsd.edu
 * Case insensitivity
 * HTTP://WWW.BLAH.COM
 * http://www.BLAH.com
 * Special Chars(allowable)
 * TODO: Need Example
 * Special Chars (not-allowable)
 * TODO: Need Example

IP Address
TODO

=Credit Card Info=

Credit Card Types

 * Valid Types
 * Visa
 * Mastercard
 * AmericanExpress
 * Discover
 * Non-Supported Types
 * Diners Club
 * JCB
 * Abbreviations
 * MC
 * AMEX
 * Case Sensitive
 * AMEX
 * VISA
 * MASTERCARD
 * DISCOVER
 * Spaces
 * Space in middle
 * American Express
 * No spaces
 * AmericanExpress
 * Leading spaces
 * " Visa"
 * " Visa"
 * Trailing spaces
 * "Visa "
 * "Visa "

Lengths

 * Valid Lengths (in digits)
 * Visa(13 & 16)
 * Mastercard (16)
 * AmericanExpress (15)
 * Discover (16)
 * Diners Club (14)
 * JCB (16)
 * Invalid Length
 * Card that passes mod10, but is too short
 * Card that passes mod10, but is too long

Formats

 * Valid Formats (Specified as valid prefixes for the credit card)
 * Visa - Must start with a '4' ex. (4567,...)
 * Mastercard - Must start with anything between 51-55 inclusive. ex (5100,5300 ...)
 * AmericanExpress (15) - Must start with either a 34 OR 37. ex (3400,3759,...)
 * Discover (16) - Must start with a 6011.
 * Diners Club (14) - Must start with anything between 300-305 OR either 36 and 38. ex (3021,3674,3874,...)
 * JCB (16) - Must start with anything between 352800-358999. ex (355000,357899,...)
 * Invalid Formats
 * Any combinations that do not fit the above criteria including
 * Credit card starts with 0000 and 9999
 * Credit card contains non-digit characters

Mod10

 * All valid credit cards MUST pass the mod 10 algorithm on the credit card digits. For more info on mod 10
 * Test card that does not pass mod 10

Expiration

 * Time-line
 * Past date/expired
 * Recently expired
 * Present month/year
 * Future month/year
 * Future month/Year -- Extended (far into future)
 * 2 digit expiration for year and month
 * 10/08
 * 2 digit month, 4 digit year
 * 10/2008
 * Abbreviated Month
 * abbreviated month, 2 digit year
 * Aug 08
 * abbreviated month, 4 digit year
 * Aug 2008
 * Expiration dates with zeros
 * months with leading zeros
 * 08/2010
 * months with trailing zeros
 * 10/2009
 * years with leading zeros
 * 11/09
 * years with trailing zeros
 * 11/10
 * 11/2010

Security (3 digit code)

 * Min (3 digits)
 * Max+ (4 digits)
 * Null
 * Empty
 * Valid
 * Invalid

Scenarios


=Login Info=

Username/Password Combinations

 * Special Characters/Minimum/Maximum
 * See String section
 * Combinations
 * Valid username, valid password
 * Valid username, password belonging to another user
 * Valid username, invalid password
 * Invalid username, good password
 * Invalid username, bad password
 * Case senstivity
 * lowercase username
 * uppercase username
 * mixed case username
 * lowercase password
 * uppercase password
 * mixed case password

=Web Service & XML Testing=

Different Types of Empty/Null

 * Value = NULL
 * NULL
 * Empty String
 * ""
 * 
 * 
 * Object = NULL (note: this means that the section of XML is missing, including the tags)
 * there would be no tags for Name

Malformed XML

 * Element missing end tag
 * Example: ....
 * Element missing start tag
 * Example: ...
 * Missing right angle bracket
 * Example:  ...
 * Multiple root tags
 * Example:  ... ...
 * Overlapping tags
 * Example: ...
 * Attribute value without quotes
 * Example:  ...
 * Attribute value missing left quote
 * Example:  ...
 * Attribute value missing right quote
 * Example:  ...
 * Unclosed comment tag before content
 * Example: &lt;!-- ... ...
 * Unclosed comment tag after content
 * Example: ... &lt;!--
 * Empty string

=File & Folder=
 * Permissions
 * Existence
 * Length of Names
 * Type of File
 * TODO

=Databases=
 * Validations before Starting to Test
 * Firewall Timeouts
 * Confirming that the DB Connection Pool times out before the firewall does so that you don't have dead connections to the database
 * Permissions/Access
 * Seeded Data/Confirm that starting data is in database
 * Stored Procedure & Schema Changes
 * Are the Stored Procedures installed in the environment
 * Has the Schema been updated
 * Data
 * Times/Dates
 * Is the system in the right time zone
 * Is the system on a 24 Hour or 12 Hour Clock
 * Is the system synced with the Application Server
 * Can the Millisecond become an issue?
 * Deletion of Data from a Database
 * Physical verses Logical Deletions (Should data ever really be deleted, or just archived?)
 * Commit/Rollback/Transactions
 * Confirm that transactions are properly handled
 * Are things written to the database when they returned an error
 * What status is given if the database cannot processs the request
 * How does the system deal with deadlocks and concurrency issues

=Networking=

=Sessions=

=Cookies= =SSL=

=UI Testing=

Error Behavior

 * TODO

Portal Behavior

 * TODO

Alt-tags/Mouse-overs

 * Confirm there is text on links when you mouse-over them
 * Confirm the use of alt-tags is consistent

Resolution

 * 800x600 is the standard, but this will change as monitors become more capable
 * 1280 x 1024 is another typical resolution
 * try at least 1 smaller resolution just so you know how it behaves (ex: 2048x1536)

Resizing browser window

 * content should typically remain centered, or stay to the left
 * content should not end up with additional spacing in the middle

Busy Signal

 * Anytime the system is doing a search
 * Anytime the system has to go to a server to look up data
 * Anytime the action could take longer than 2 seconds
 * Anytime the user is going to be blocked from doing other activities

Tab Order

 * Should be able to tab to all available links
 * Order of tabbing should make sense

Short-cut Keys (Hot Keys)

 * not many sites have these, but if they do you'll need to test them (ex: ctlr-s for Save)

Browser Title Bar

 * title of page shown should make sense, this will be used for a bookmark, so you might want to make sure they are distinctive

Browser Version

 * See Project Requirements
 * TODO

Javascript

 * Enabled
 * Disabled

Cookies

 * Enabled
 * Disabled

Browser Security

 * Differs per browser

Browser Cache

 * Make sure you try tests with/without it cleared

Embedded Browsers

 * TODO

Accessibility

 * TODO (See IEEE)

Pop-Up Blockers

 * TODO

Busy Signal

 * Anytime the system is doing a search
 * Anytime the system has to go to a server to look up data
 * Anytime the action could take longer than 2 seconds
 * Anytime the user is going to be blocked from doing other activities

Short-cuts Keys

 * Anytime you are in a menu
 * Anytime you are doing an action that the user will be doing more than twice
 * Anytime you are doing an action that will be difficult for a QA team to automate (wintree forms)

Window Re-sizing

 * Minimize using the minimize link on the title bar
 * Minimize using title bar of application(double click on title bar)
 * Minimize by trying to drag in the corner of the application
 * Minimize by trying to drag in the bottom of the application
 * Maximize using the minimize link on the title bar
 * Maximize using title bar of application(double click on title bar)
 * Maximize by trying to drag in the corner of the application
 * Maximize by trying to drag in the bottom of the application

Resolution

 * Smaller Resolution
 * 800x600
 * 1024x768
 * Average Resolution
 * 1280x1024
 * 1400x1050
 * 1600x1200
 * Larger Resolution
 * 2048x1536

Drop-down

 * default value (Ex: default value can be "no selection")
 * All possible values available (Ex: for a state field, is a state missing?)
 * Can I select the value I want

Checkbox

 * TODO

Radio Buttons

 * TODO

=Installation Testing=

Successful Install
Note: For all of the validations you need to not only validate what should exist, but to confirm that nothing is installed that should not be present. (a.k.a. Do a complete dif)
 * Validate Registry
 * Validate GAC
 * Validate File System
 * Validate Running Services (windows services)

Failed Repair/Unsuccessful Repair
=Monitoring & Alerts= =Logging=
 * TODO
 * TODO

=Locale Testing=
 * Blog post about how sorting strings can vary on different locales
 * Examples of Items Effected by Locale
 * Dollars Amounts/Currency
 * Phone #'s
 * Zip Codes
 * Address Standardization
 * Dates/Times
 * Time zones
 * Reading Style (Right to left?)
 * Character Sets
 * Test with entire available character set for that given locale
 * Ability to retrieve entire character set after storage in DB
 * UI aspects
 * buttons/layout sized for English words
 * Is everything really translated that should be (example: privacy, help, etc)
 * Hot keys (Short-cut keys)
 * Best Practices for Web Services
 * i18n JUnit Testcases
 * Java Tutorial on i18n

=Misc=

Dollar Amounts

 * Rounding Off verses truncating
 * 10.56 -> 11 (round up to integer)
 * 10.56 -> 10.6 (round up to nearest decimal)
 * 10.47 -> 10 (round down to integer)
 * 10.477 -> 10.47 (truncated)
 * #'s that End in 0
 * 10
 * 10.0
 * 10.00
 * 1.90
 * 1700.30
 * 10.000