Transcript of "Software testing and software development process"
SOFTWARETESTING ANDSOFTWARETESTING ANDSOFTWARE DEVELOPMENTSOFTWARE DEVELOPMENTPROCESS (SDP)PROCESS (SDP)Aloysius Ochola2010/HD18/431UMAKERERE UNIVERSITYSchool of Computing and InformaticsTechnologyMCN 8108MCN 8108 Software Quality Assurance & TestingSoftware Quality Assurance & TestingMscCS Class Presentations. Nov. 2011
SoftwareTestingSoftwareTestingPrograms are implemented to provide a concreterepresentation of an algorithm◦ major concern is with the correctness and performance of theimplementation.Engineers must then ensure that their softwaresystems achieve an appropriate level of qualitySoftware verification (through correctness proof)◦ Technique to assist during the specification, design, andimplementation of a software systemSoftware testing (alternative for verification)◦ Process of assessing the functionality and correctness of aprogram through execution or analysis◦ Basically a methodology to find bugs in a software with anintent to fix them2 Software Testing and the SDP
SoftwareTesting (cont)SoftwareTesting (cont)Software testing is more than just error detection.Looked at as operating the software undercontrolled conditions to verify that it behaves asspecified to detect errors and validate that what hasbeen specified is what the user actually wanted.◦ Verification - check or test items, including software,for conformance and consistency by evaluating theresults against pre-specified requirements. Check if we are building what the customer wants Qn. Are we building the system right?◦ Error Detection - Testing should intentionally attemptto make things go wrong. Determine if things happen when they shouldn’t or things don’thappen when they should.3 Software Testing and the SDP
SoftwareTesting (cont)SoftwareTesting (cont)◦ Validation (system correctness) - process ofchecking that what has been specified is whatthe user actually wanted. Check if we are building that system correctly Qn. Are we building the right system?Both verification and validation arenecessary, but different components of anytesting activity.4 Software Testing and the SDP
Limits of SoftwareTestingLimits of SoftwareTestingCan not test a program completely◦ Completeness means that at the end of testing,there are no undiscovered software errors.Whether theyve been fixed is a different issue,but all problems must be known andunderstood◦ Why complete testing is impossible The domain of possible inputs is too large to test There are too many possible paths through theprogram to test The user interface issues (and thus the design issues)are too complex to completely test5 Software Testing and the SDP
Limits of S.T(cont…)Limits of S.T(cont…)Testing can only prove the presence of bugsbut never their absenceYou can not test the program’s response toevery possible input◦ The number of test inputs, even for this simple aprogram, is huge.You can not test every path the program cantake◦ As with testing input data, it is important to realizethat you have not completely tested the programunless you have exercised every path.◦ No such paths as safe to skipSoftware Testing and the SDP6
Limits of S.T(cont…)Limits of S.T(cont…)You can not find every design error◦ A program meets the specification by doingexactly what a specification says it should◦ If specification goes wrong? Ex.Asks for 1x1=11◦ Being in the specification doesnt make them right◦ You cant completely test a program if you cantfind all of its design errorsYou can not prove programs correct usinglogic◦ can only validate the internal consistency of theprogram◦ What if the specifications were wrong?Software Testing and the SDP7
Limits of S.T(cont…)Limits of S.T(cont…)You can not verify that the program workscorrectly◦ A tester is interested in verifying the program◦ How? If the program can not be testedcompletelySoftware Testing and the SDP8
Objectives of Testing SoftwareObjectives of Testing SoftwareThe purpose of testing is verification,validation and error detection in order tofind problems. And the purpose of findingthose problems is to get them fixed.Testing Software to Find Problems◦ Executing a program with the intent of finding anerror◦ Check if the system meets the requirements andbe executed successfully in the Intendedenvironment◦ Check if the system is “ Fit for purpose”◦ Check if system does what it is expected to do9 Software Testing and the SDP
Objectives of Testing SoftwareObjectives of Testing SoftwareFinding Problems to Fix them◦ One benefit of testing is that it results inimproved quality◦ uncovering yet undiscovered errors◦ Fixing bugs◦ You take a destructive attitude toward theprogram when you testSoftware Testing and the SDP10
Testing Life-Cycle PhasesTesting Life-Cycle PhasesBasically 5 stages involved includeRequirements Study◦ Understanding of the requirements is very essential fortesting a product◦ So we set a starting point to the study of the client’srequirements◦ Involves the analysis and planning phase, encapsulates Test objective and coverage Overall schedule Standards and Methodologies Resources required, including necessary training Roles and responsibilities of the team members Tools usedSoftware Testing and the SDP11
Testing Life-cycle phasesTesting Life-cycle phasesTest Case Design and Development◦ Identify Components◦ Test Specification Design◦ Test Specification ReviewsTest Execution◦ Code Review◦ Test execution and evaluation◦ Performance and simulationTest Closure◦ Test summary report◦ Project DocumentationTest Process Analysis◦ Done on the reports and improving the performance ofapplication by implementing new technology.Software Testing and the SDP12
SoftwareTesting TechniquesSoftwareTesting Techniques Different techniques are used for software techniques.The commonly used are the following Black BoxTesting (functional/behavioural)◦ No knowledge of internal design or code required.13 Software Testing and the SDP◦ focus on outputs inresponse toselected inputs andexecutionconditions◦ Tests are based onrequirements andfunctionality.
White box testingWhite box testing (Glass box)◦ Takes into account the internal mechanism of thesystem◦ White Box is most appropriate when we mustassure that the calculations are correct.◦ Covering every possible path through a module isusually not practical Goal is to ensure that all conditional statements havebeen executed at least once◦ Requirements fulfilments and interface availabilityand working assurance Grey BoxTestingGrey BoxTesting◦ The combination of White and Black box testingSoftware Testing and the SDP14
Stages of SoftwareTestingStages of SoftwareTestingUnitTesting Micro scale of testing done on particular functions or codemodules Internal program design and code knowledge is required Thus, done by Programmers after modules have been coded. Objectives◦ To test the function of a program or unit of code such as a module◦ To test internal logic◦ To verify internal design◦ To test path and conditions coverage◦ To test exception conditions & error handling White box testing and test coverage techniques deployed Tools guiding unit testing include; Debug, Re-structure, codeanalyzers and path coverage toolsSoftware Testing and the SDP15
IntegratedTesting Testing of combined parts of an application to determinetheir functional correctness Done to technically verify proper interfacing between modulesand within sub-systems. Always carried out by developers after modules are unittested White Box, Black box and configuration management,techniques used. Types of Integrated Testing◦ Bottom - up testing (test harness)◦ Top - down testing (stubs).◦ Modified top - down testing - test levels independently.◦ Big Bang◦ Sandwich testingSoftware Testing and the SDP16
SystemTestingMajor objectives include◦ Verify that system components perform controlfunctions◦ To perform inter-system test◦ To perform appropriate types of tests relating totransaction flows, installation, reliability, regression, etcIt is done by both users and the developmentteam after integration testingSystem integrated testing is often carried outafter system testing but outside the project lifecycle◦ Tests the co-existence of products and applicationsthat are required to perform together in a production-like operational environmentSoftware Testing and the SDP17
AcceptanceTestingThis is performed by the end usersTo verify that the system meets theirrequirements.Black box technique is appliedTools used may include:◦ Comparison◦ Keystroke capture◦ Playback◦ Regression testingSoftware Testing and the SDP18
Types of SoftwareTestingTypes of SoftwareTestingWe have come across so many types ofsoftware testingTwo major approaches of software testing◦ Manual testing – done by man. Tester runs thesoftware for errors. Consumes a lot of timebecause testing has to be repeated after everychange (regression testing)◦ Automated testing – Testing employing softwaretools which execute tests without manualintervention performed by writing test drivers that can runautomatically and produce test results19 Software Testing and the SDP
Major Types of TestingMajor Types of Testing LoadTesting◦ Testing an application under heavy loads◦ Ex,Testing of a web site under a range of loads to determine,when the system response time degraded or fails. StressTesting◦ Program is checked to see how well it deals with abnormalresource demands◦ Testing under heavy loads, heavy repetition of certain actionsor inputs◦ Ex. input of large numerical values, large complex queries to adatabaseSoftware Testing and the SDP20
PerformanceTesting◦ Tests the run-time performance of software◦ How well does the application comply to performancerequirements? RecoveryTesting◦ Checks system’s ability to recover from failures◦ How well can it recovers from crashes, hardware failures orother problems? ConversionTesting◦ Testing of programs or procedures used to convert data fromexisting systems for use in replacement system◦ Ensures that the existing data should not change,while converting it into the new updated version of theapplicationSoftware Testing and the SDP21
UsabilityTesting◦ A method by which users of a product are asked toperform certain tasks in an effort to measure theproducts ease-of-use, task time, and the usersperception of the experience◦ Testing the ease with which users can learn and use aproduct ConfigurationTesting◦ Focuses on measuring a human-made products capacityto meet its intended purpose◦ Causes the application to fail to meet its configurabilityrequirements so that the underlying defects can beidentified, analyzed, fixed, and prevented in the futureSoftware Testing and the SDP22
Software Development ProcessSoftware Development Process A structure imposed on the development of a softwareproduct There are several models for such processes, each describingapproaches to a variety of tasks or activities that take placeduring the process. Activities involved◦ Planning◦ Design◦ Coding and Documentation◦ Testing and Fixing◦ Post-Release Maintenance and EnhancementTesting is involved mainly in the functional phases of thesoftware development process.It is necessary that it is encapsulated in the whole process23 Software Testing and the SDP
SummarySummaryTesting in itself cannot ensure the qualityof softwareOnly gives us a certain level of confidencein the softwareTesting though, proves that under specificcontrolled conditions, the softwarefunctioned as expected by the test casesexecutedTesting never ends as long as a software isstill in use24 Software Testing and the SDP
ReferencesReferences Manish Parashar: Software Testing, Introduction to SoftwareEngineering; Lecture Notes C. Kaner , J. Falk and H.Q Nguyen:Testing Computer Software. Different types of software retrieved Nov 2011 fromhttp://www.wisegeek.com/what-are-the-different-types-of-system-software.htm Roger S. Pressman: Software Engineering; 5thEdition. Ram Chillarege (1999): Software Testing Best Practices, IBM ResearchTechnical Report What is Software Testing … ? Retrieved Nov. 2011 from:http://bazman.tripod.com/what_testing.html Antonia Bertolino (2001): SoftwareTesting25 Software Testing and the SDP
A particular slide catching your eye?
Clipping is a handy way to collect important slides you want to go back to later.