Published on

Published in: Education
  • Be the first to comment

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide


  1. 1. Software testing 3. Test types Dr. Balla Katalin
  2. 2. Contents <ul><li>Testing or inspection? </li></ul><ul><li>Test types </li></ul>
  3. 3. Testing <ul><li>The process that helps understanding the correctness, completeness and quality of the software </li></ul><ul><ul><li>Testing cannot entirely prove the correctness of the software. Lack of errors can be demonstrated only by using formal methods. </li></ul></ul>
  4. 4. Testing or review / inspection / auditing? <ul><li>Review, inspection, audit: are in fact a way of testing. However… </li></ul><ul><ul><li>In everyday discussions we usually use „testing” for code, and „review / inspection / audit” for something else than code (eg. specification, plans, user documentation etc.) </li></ul></ul>
  5. 5. Inspection, review, audit <ul><li>Inspection: assessment of any work product, executed by trained professionals, according to well-defined rules. Scope: find defects. </li></ul><ul><ul><li>Basic idea: we do not find our own bugs… </li></ul></ul><ul><li>Inspection: can be applied in any phase of development to: specification, plans, code, test cases… </li></ul><ul><li>Inspection: often used for checking the code </li></ul>
  6. 6. Inspection <ul><li>Might reduce testing cost to 20-30 % of development cost. </li></ul><ul><li>Good inspection might result in omitting unit test and integration test. System test will be enough. </li></ul><ul><li>Eg: inspection of system design compared to specification, code inspection compared to system design etc. </li></ul>
  7. 7. Test types <ul><li>Many groupings are possible </li></ul><ul><ul><li>redundancy, overlap </li></ul></ul><ul><li>Eg: grouping by: </li></ul><ul><ul><li>Tested item </li></ul></ul><ul><ul><li>Place in lifecycle </li></ul></ul><ul><ul><li>Person doing the test </li></ul></ul><ul><ul><li>Usage of test results </li></ul></ul><ul><ul><li>Techniques used… </li></ul></ul>
  8. 8. Test types <ul><ul><li>Tested item </li></ul></ul><ul><ul><li>Place in lifecycle </li></ul></ul><ul><ul><li>Person doing the test </li></ul></ul><ul><ul><li>Usage of test results </li></ul></ul><ul><ul><li>Techniques used… </li></ul></ul>
  9. 9. Test types <ul><li>By tested item </li></ul><ul><ul><li>Component / unit -test </li></ul></ul><ul><ul><li>Integration test </li></ul></ul><ul><ul><li>System test </li></ul></ul>
  10. 10. Test types by tested item <ul><li>Unit test / component test </li></ul><ul><ul><li>Units / components are tested against specification. One unit: one or more procedures, functions </li></ul></ul><ul><ul><li>Is a testing method to check the correctness of a part of the code. </li></ul></ul><ul><ul><li>Basic idea: develop a test case for all non-trivial functions, methods of a module, having mutually separate test cases (one test case test exactly one item, does not interfere with others) </li></ul></ul>
  11. 11. <ul><li>Integration test </li></ul><ul><ul><li>Units are integrated and the interfaces are tested against their specification </li></ul></ul><ul><ul><li>It is usually executed after unit testing, before system testing </li></ul></ul><ul><ul><li>Uses modules already unit-tested </li></ul></ul><ul><ul><li>It has the scope to check the requirements regarding the functionality of larg(er) items. </li></ul></ul><ul><ul><li>Interfaces between modules are checked. </li></ul></ul><ul><ul><li>Testing is done by simulating cooperation between modules. </li></ul></ul><ul><ul><li>Basic idea: we always use units that are tested already </li></ul></ul>Test types by tested item
  12. 12. <ul><li>System test </li></ul><ul><ul><li>The entire system is tested against its specification </li></ul></ul><ul><ul><li>Input to test: (sub)system(s) that have successfully pass their test </li></ul></ul><ul><ul><li>System test must be understood by the user. </li></ul></ul><ul><ul><li>In many cases system test and acceptance test are connected. </li></ul></ul>Test types by tested item
  13. 13. <ul><li>Composing the test </li></ul><ul><ul><li>Test the units / components </li></ul></ul><ul><ul><li>Integrate components into subsystems- test subsystems </li></ul></ul><ul><ul><li>Continue integration, until the entire system can be tested </li></ul></ul>Test types by tested item
  14. 14. Test types by tested item <ul><li>Are connected in fact to life cycle phases </li></ul>Requirement specification High level design Unit test Integration test System test Detailed design Coding
  15. 15. Test types by tested item <ul><li>Regression test: we prove that all that was functioning in previous build is still functioning </li></ul><ul><ul><li>Experience: each fifth modification injects a new bug </li></ul></ul><ul><li>Progression testing : we assume that integration test has been successfully performed, and we test only the new functions </li></ul>
  16. 16. Test types <ul><ul><li>Tested item </li></ul></ul><ul><ul><li>Place in lifecycle </li></ul></ul><ul><ul><li>Person doing the test </li></ul></ul><ul><ul><li>Usage of test results </li></ul></ul><ul><ul><li>Techniques used </li></ul></ul>
  17. 17. Test types by place in the lifecycle <ul><li>Show the „readiness” of the software, the degree of progress and the part still to be done in the software development </li></ul><ul><li>Basic cases: </li></ul><ul><ul><li>Pre-alfa status („half-way ready”, not yet complete) </li></ul></ul><ul><ul><li>Alfa status (new elements have been added) </li></ul></ul><ul><ul><li>Beta status (we are actively looking for bugs) </li></ul></ul><ul><ul><li>Stable status (most severe bugs have been corrected) </li></ul></ul><ul><ul><li>Release-candidate (Microsoft: „RTM” – release to manufacturing) (ready to be released) </li></ul></ul><ul><ul><li>Release / gold status (released) </li></ul></ul><ul><ul><li>… </li></ul></ul><ul><li>Further intermediate states can be identified … </li></ul>
  18. 18. Test types by place in the lifecycle <ul><li>Pre-alfa test: developer test of ceratin functions </li></ul><ul><li>Alfa test: internal system test by developer </li></ul><ul><li>Beta test: restricted number of users are testing the system </li></ul><ul><ul><li>(Gamma test, gamma version: funny, ironical name for a system full of bugs) </li></ul></ul><ul><ul><li>Gamma, delta, omega tests: tests of more and more developed releases </li></ul></ul>
  19. 19. Test types <ul><ul><li>Tested item </li></ul></ul><ul><ul><li>Place in lifecycle </li></ul></ul><ul><ul><li>Person doing the test </li></ul></ul><ul><ul><li>Usage of test results </li></ul></ul><ul><ul><li>Techniques used </li></ul></ul>
  20. 20. Test types by person doing the test <ul><li>Designer test </li></ul><ul><li>Developer test </li></ul><ul><li>User test </li></ul><ul><li>Test executed jointly, by more stakeholders </li></ul><ul><ul><li>Joint reviews </li></ul></ul>
  21. 21. Test types <ul><ul><li>Tested item </li></ul></ul><ul><ul><li>Place in lifecycle </li></ul></ul><ul><ul><li>Person doing the test </li></ul></ul><ul><ul><li>Usage of test results </li></ul></ul><ul><ul><li>Techniques used </li></ul></ul>
  22. 22. Test types by usage of the test results <ul><li>A decision (official) is taken based on the test results </li></ul><ul><li>Testing is executed to… </li></ul><ul><ul><li>Qualify the system – qualification test </li></ul></ul><ul><ul><li>Hand over / accept the system – acceptance test </li></ul></ul><ul><ul><li>Show that the system is operating as planned - operational test </li></ul></ul><ul><ul><li>Install the system – installation test </li></ul></ul><ul><ul><li>Jointly review the system – joint review </li></ul></ul><ul><ul><li>Verify the system – verification / assessment </li></ul></ul><ul><ul><li>… </li></ul></ul>
  23. 23. Test types by usage of the test results <ul><li>Qualification testing: </li></ul><ul><ul><li>System qualification testing is performed to demonstrate to the acquirer that system requirements have been met. It covers the system requirements in the system/subsystem specifications and in associated interface requirements specifications. </li></ul></ul>
  24. 24. Test types by usage of the test results <ul><li>Acceptance test </li></ul><ul><ul><li>acceptance testing is testing performed on a system . </li></ul></ul><ul><ul><li>In some engineering subdisciplines , it is known as functional testing, black-box testing , release acceptance , QA testing, application testing, confidence testing, final testing, validation testing, usability testing , or factory acceptance testing. </li></ul></ul><ul><ul><li>In most environments, acceptance testing by the system provider is distinguished from acceptance testing by the customer (the user or client) prior to accepting transfer of ownership. In such environments, acceptance testing performed by the customer is known as beta testing , user acceptance testing , end user testing, site (acceptance) testing, or field (acceptance) testing. </li></ul></ul>
  25. 25. Test types by usage of the test results <ul><li>Operational test </li></ul><ul><ul><li>An operational test is performed before handing over each version of a software. The software is put into real operation only if the operational test was successful. </li></ul></ul><ul><ul><li>This test ensures that the software is entering into operation, is operating and stops operating according to the plan. </li></ul></ul>
  26. 26. Test types by usage of the test results <ul><li>Installation test </li></ul><ul><ul><li>Test performed outside the development environment </li></ul></ul><ul><ul><li>In some cases installation requires setting / modifying of some parameters in the running environment. In such cases it is useful to have a back-up procedure. </li></ul></ul>
  27. 27. Test types by usage of the test results <ul><li>Joint review </li></ul><ul><ul><li>This process provides the framework for interactions between the reviewer and the reviewee. They may as well be the acquirer and the supplier respectively. </li></ul></ul><ul><ul><li>At a joint review, the reviewee presents the status and products of a life cycle activity of a project to the reviewer for comment (or approval). The reviews are at both management and technical levels. (ISO 12207) </li></ul></ul>
  28. 28. Test types by usage of the test results <ul><li>Audit </li></ul><ul><ul><li>This process provides the framework for formal, contractually established audits of a supplier's products or services. At an audit, the auditor assesses the auditee's products and activities with emphasis on compliance to requirements and plans. An audit may well be conducted by the acquirer on the supplier. (ISO 12207) </li></ul></ul>
  29. 29. Test types <ul><ul><li>Tested item </li></ul></ul><ul><ul><li>Place in lifecycle </li></ul></ul><ul><ul><li>Person doing the test </li></ul></ul><ul><ul><li>Usage of test results </li></ul></ul><ul><ul><li>Techniques used </li></ul></ul>
  30. 30. Test types by techniques used <ul><li>At different levels different testing techniques are used. </li></ul><ul><li>At all levels the desired result can be achieved by combining multiple techniques. </li></ul>
  31. 31. Test types by techniques used <ul><li>Static testing </li></ul><ul><li>Dynamic testing </li></ul><ul><ul><ul><li>Structural testing </li></ul></ul></ul><ul><ul><ul><li>Functional testing </li></ul></ul></ul><ul><li>These will be discussed in detail in the following lectures </li></ul>
  32. 32. Test types by techniques used <ul><li>Some consider to be techniques: </li></ul><ul><ul><li>Validation </li></ul></ul><ul><ul><ul><li>Validation determines whether the final, as-built system fulfills its specific intended use. The extent of validation depends upon the project's criticality. Validation does not replace other evaluations, but supplements them. </li></ul></ul></ul><ul><ul><li>Verification </li></ul></ul><ul><ul><ul><li>This process provides the evaluations related to verification of a product or service of a given activity. Verification determines whether the requirements for a system are complete and correct and that the outputs of an activity fulfill the requirements or conditions imposed on them in the previous activities. The process covers verification of process, requirements, design, code, integration, and documentation. Verification does not alleviate the evaluations assigned to a process; on the contrary, it supplements them. </li></ul></ul></ul><ul><ul><li>Verification or validation may be conducted by the acquirer, the supplier, or an independent party. When they are executed by an organization independent of the supplier or developer, they are called independent verification and validation (IV&V) Process. </li></ul></ul><ul><ul><li>ISO 12207 </li></ul></ul>
  33. 33. Test types by other criteria <ul><li>There are other g r oupings also. </li></ul><ul><li>New groups can be formed by combining elements of the previously presented ones. </li></ul><ul><ul><li>By (place in the life cycle + participants in the tes t ing + test results) </li></ul></ul><ul><ul><li>By algorithm used in testing </li></ul></ul><ul><ul><li>… </li></ul></ul>
  34. 34. Test types by other criteria <ul><li>„Manual” testing </li></ul><ul><li>Automated testing </li></ul><ul><ul><li>Testing done based on scripts developed by the user or tester </li></ul></ul><ul><ul><li>Testing using automated testing tools </li></ul></ul>
  35. 35. Test types by other criteria <ul><li>Load testing </li></ul><ul><ul><li>Load testing is a generic term covering Performance Testing and Stress Testing. </li></ul></ul>
  36. 36. Test types by other criteria <ul><li>Performance testing </li></ul><ul><ul><li>Performed, from one perspective, to determine how fast some aspect of a system performs under a particular workload. It can also serve to validate and verify other quality attributes of the system, such as scalability, reliability and resource usage. </li></ul></ul>
  37. 37. Test types by other criteria <ul><li>Stress testing </li></ul><ul><ul><li>Testing conducted to evaluate a system or component at or beyond the limits of its specified requirements to determine the load under which it fails and how. </li></ul></ul><ul><ul><li>A graceful degradation under load leading to non-catastrophic failure is the desired result. </li></ul></ul><ul><ul><li>Often Stress Testing is performed using the same process as Performance Testing but employing a very high level of simulated load </li></ul></ul>
  38. 38. Test types by other criteria <ul><li>Model based testing </li></ul><ul><ul><li>Test cases are generated automatically from a model describing the behaviour of the system </li></ul></ul><ul><ul><ul><li>Eg: UML - Activity diagram </li></ul></ul></ul>
  39. 39. Test types by other criteria <ul><li>Usability testing </li></ul><ul><ul><li>Usability testing focuses on measuring a human-made product's capacity to meet its intended purpose. Examples of products that commonly benefit from usability testing are web sites or web applications, computer interfaces , documents, or devices. Usability testing measures the usability , or ease of use, of a specific object or set of objects, whereas general human-computer interaction studies attempt to formulate universal principles. </li></ul></ul>
  40. 40. Test types by other criteria <ul><li>Usability testing </li></ul><ul><ul><li>Usability testing generally involves measuring how well test subjects respond in four areas: time, accuracy, recall, and emotional response. The results of the first test can be treated as a baseline or control measurement; all subsequent tests can then be compared to the baseline to indicate improvement. </li></ul></ul><ul><ul><ul><li>Time on Task -- How long does it take people to complete basic tasks? (For example, find something to buy, create a new account, and order the item.) </li></ul></ul></ul><ul><ul><ul><li>Accuracy -- How many mistakes did people make? (And were they fatal or recoverable with the right information?) </li></ul></ul></ul><ul><ul><ul><li>Recall -- How much does the person remember afterwards or after periods of non-use? </li></ul></ul></ul><ul><ul><ul><li>Emotional Response -- How does the person feel about the tasks completed? (Confident? Stressed? Would the user recommend this system to a friend?) </li></ul></ul></ul>
  41. 41. Test types by other criteria <ul><li>Stability testing </li></ul><ul><ul><li>Has the scope to unders t and whether a system will be able to function, what is the probability that it fails </li></ul></ul>
  42. 42. Test types by other criteria <ul><li>Security Testing: </li></ul><ul><ul><li>Process to determine that an Information System protects data and maintains functionality as intended. </li></ul></ul><ul><ul><li>The six basic security concepts that need to be covered by security testing are: confidentiality, integrity, authentication, authorisation, availability and non-repudiation. </li></ul></ul><ul><li> </li></ul>
  43. 43. Test types by other criteria <ul><li>Security Testing – basic concepts </li></ul><ul><ul><li>Confidentiality </li></ul></ul><ul><ul><li>A security measure which protects against the disclosure of information to parties other than the intended recipient that is by no means the only way of ensuring confidentiality. </li></ul></ul><ul><ul><li>Integrity </li></ul></ul><ul><ul><li>A measure intended to allow the receiver to determine that the information which it receives has not been altered in transit or by other than the originator of the information. </li></ul></ul><ul><ul><li>Integrity schemes often use some of the same underlying technologies as confidentiality schemes, but they usually involve adding additional information to a communication to form the basis of an algorithmic check rather than the encoding all of the communication. </li></ul></ul><ul><ul><li>Authentication </li></ul></ul><ul><ul><li>A measure designed to establish the validity of a transmission, message, or originator. </li></ul></ul><ul><ul><li>Allows a receiver to have confidence that information it receives originated from a specific known source. </li></ul></ul>
  44. 44. Test types by other criteria <ul><li>Security Testing – basic concepts </li></ul><ul><ul><li>Authorization </li></ul></ul><ul><ul><li>The process of determining that a requester is allowed to receive a service or perform an operation. </li></ul></ul><ul><ul><li>Access control is an example of authorization. </li></ul></ul><ul><ul><li>Availability </li></ul></ul><ul><ul><li>Assuring information and communications services will be ready for use when expected. </li></ul></ul><ul><ul><li>Information must be kept available to authorized persons when they need it. </li></ul></ul><ul><ul><li>Also authority to operate </li></ul></ul><ul><ul><li>Non-repudiation </li></ul></ul><ul><ul><li>A measure intended to prevent the later denial that an action happened, or a communication that took place etc. </li></ul></ul><ul><ul><li>In communication terms this often involves the interchange of authentication information combined with some form of provable time stamp </li></ul></ul>
  45. 45. Test types by other criteria <ul><li>Conformance testing / type testing </li></ul><ul><ul><li>Executed to see if a system is conform or not to the requirements of a standard or law. </li></ul></ul><ul><ul><li>Many standards contain conformance criteria. </li></ul></ul><ul><ul><li>Conformance testing is often executed by third parties, eg. the standardization body. </li></ul></ul>
  46. 46. What we talked about… <ul><li>Testing or inspection? </li></ul><ul><li>Test types </li></ul>