70 likes | 85 Views
Learn about test plans, test-driven development, code coverage, automated regression, and more. Understand the importance of user acceptance, system, and unit tests, along with how to validate flows and specifications. Discover how to create good test cases and utilize various testing environments for successful testing. This guide covers levels of testing, structure, TDD, and choosing test cases effectively. Start improving your testing practices today!
E N D
Test Plans • Test Driven Development • Unit test plan first • Code coverage • Automated Regression built as you go • Debug is easier • Serves as system doc • Still need system test on top • Legacy code might not have the plans
Test Plan levels • User Acceptance • System (integration) • Unit test (TDD concerned with these) • Regression
Type • Try to break it • Validate flows (from state to state) • Validate Specifications (including use cases and sequence diagrams) • Stress test • Code inspection • Black box vs white box • Black - From spec - no design knowledge • White - look at code to find decisions
A Good Test Case • Setup situation - environment to input into • Action to test - actual input • Assertion of result - what the environment looks like when you are done
Chose cases • Input / output partitions (similar characteristics) • One from each paritition; boundaries and null • Cause all failure types (every failure error msg) • Sequences: have only 1 in a sequence; have none in a sequence; also act on first, middle and last • Input / output buffer overflow • Try to force invalid outputs
Environments • Good test environments encourage good tests • Refresh periodically • One per user + One shared • Bypass Database with stubs to return from a DB call • Quick • Not complete
Testing Wrap UP • Levels - unit / system / user • Structure - situation / input / expected output • TDD - code test before coding program • Choose cases - partitions (border, null, sample) / sequences / buffer limits / force errors • You will be able to : • Write a user acceptance test plan • Write good test cases on paper