Gabriele Lana: Testing Web Applications

4,176 views
4,090 views

Published on

Published in: Technology
1 Comment
6 Likes
Statistics
Notes
  • The usage of imagery in this slideshow is very effective. You have done a fantastic job here friend.
    Teisha
    http://dashinghealth.com http://healthimplants.com
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
No Downloads
Views
Total views
4,176
On SlideShare
0
From Embeds
0
Number of Embeds
49
Actions
Shares
0
Downloads
194
Comments
1
Likes
6
Embeds 0
No embeds

No notes for slide

Gabriele Lana: Testing Web Applications

  1. 1. Testing Web Applications Gabriele Lana www.gabrielelana.it info@gabrielelana.it
  2. 2. Debug Sucks Test Rocks
  3. 3. Why Test Automation?
  4. 4. Prevent Change
  5. 5. Hard To Change Costo Costo x Modifica nel Tempo Tempo
  6. 6. Always Change 60%-80% of all software is developed after first release to production
  7. 7. Reject Change Costo x Modifica Costo Insostenibile E' impossibile lavorarci! Rifacciamolo! Tempo
  8. 8. Automatic Test What = Test How = Code
  9. 9. Embrace Change Costo Tempo
  10. 10. Embrace Change = Sostenibilità
  11. 11. Bug Fixing
  12. 12. Bug Fix Costo #Bugs
  13. 13. #Bugs? Costo Totale = Costo (Numero Bugs)? X (Costo del singolo Bug) #Bugs
  14. 14. How Hard To Fix?
  15. 15. How Hard To Fix? Costo Costo Totale = (Numero Bugs)? X (Costo del singolo Bug)? #Bugs
  16. 16. Bug Repellent
  17. 17. Automatic Test Costo Lines Of Code
  18. 18. Automatic Test Costo Lines Of Code
  19. 19. Defect Prevention = Prevedibilità
  20. 20. Defect != Bug
  21. 21. Planning
  22. 22. Feedback
  23. 23. Sensing Code (Unit Tests)
  24. 24. Sensing Architecture (Functional Tests)
  25. 25. Sensing Product (Acceptance Tests)
  26. 26. Do Learn Sense
  27. 27. Feedback = Governabilità
  28. 28. Automatic Tests => Sostenibilità Prevedibilità Governabilità
  29. 29. Test Automation Lifecycle
  30. 30. Fixture All the things we need to have in place in order to run a test and expect a particular outcome
  31. 31. 1: Fixture SetUp Fixture Fixture SetUp
  32. 32. SUT The “System Under Test”, whatever thing we are testing
  33. 33. 2: Exercise SUT Fixture Fixture SetUp Exercise SUT SUT
  34. 34. 3: Verify Result Fixture Fixture SetUp Exercise SUT SUT Verify Result
  35. 35. 4: Fixture TearDown Fixture Fixture SetUp Exercise SUT SUT Verify Result Fixture TearDown
  36. 36. Test Automation Identity
  37. 37. Tools
  38. 38. Who? What? Why?
  39. 39. Who? Chi lo scrive? A chi da valore? Chi lo legge?
  40. 40. What? Quali sono le Qual'è il SUT? condizioni?
  41. 41. Why? Qual'è lo scopo? Cosa voglio verificare? Quali informazioni voglio avere?
  42. 42. Unit Tests
  43. 43. Who? Developers
  44. 44. What? Unit Of Code
  45. 45. Why? Verify Code Behaviour, Code Documentation
  46. 46. Unit Test Test Function • Method • Unit Procedure • ... •
  47. 47. Unit Test Database • File System Test • Configuration • X OS • Unit
  48. 48. Unit Test Test X Network X Unit
  49. 49. Unit Test Test X X X Unit Unit
  50. 50. Tools Simple Test (http://www.lastcraft.com/simple_test.php) PHPUnit (http://www.phpunit.de)
  51. 51. 1: Fixture SetUp
  52. 52. 2: Exercise SUT
  53. 53. 3: Verify Result
  54. 54. 4: Fixture TearDown
  55. 55. If total() < 100 then no discount If daysUntilLastSelling() > 30 then no discount If daysUntilLastSelling() < 30 and total() > 100 then discount
  56. 56. New Requirement
  57. 57. If total() < 100 then no discount If daysUntilLastSelling() > 30 then no discount If daysUntilLastSelling() < 30 and total() > 100 then discount
  58. 58. Embrace Change?
  59. 59. Test Behaviour Not Code
  60. 60. If total() < 100 then no discount If daysUntilLastSelling() > 30 then no discount If daysUntilLastSelling() < 30 and total() > 100 then discount
  61. 61. If total() < 100 then no discount If daysUntilLastSelling() > 30 then no discount If daysUntilLastSelling() < 30 and total() > 100 then discount
  62. 62. If total() < 100 then no discount If daysUntilLastSelling() > 30 then no discount If daysUntilLastSelling() < 30 and total() > 100 then discount
  63. 63. Why? Test Driven Development = Code Design
  64. 64. Code Coverage
  65. 65. Integration Tests
  66. 66. Who? Developers
  67. 67. What? Units Of Code
  68. 68. Why? Verify Code Behaviour, Code Documentation, Code Design
  69. 69. Database Tests
  70. 70. Who? Developers, DBA
  71. 71. What? Stored Procedure, Complex Query, Data Migration
  72. 72. Why? Wrong data is source of bugs!
  73. 73. Functional Tests
  74. 74. Who? Developers, Customer
  75. 75. What? Application
  76. 76. Why? Verify Application Behaviour, Application Design
  77. 77. What? HTTP
  78. 78. Tools Selenium (http://www.openqa.org/selenium)
  79. 79. What? HTTP
  80. 80. What? Presentation Vs Business Logic
  81. 81. Acceptance Tests
  82. 82. Who? Customer
  83. 83. What? Application
  84. 84. Why? Product Design, Product Specification
  85. 85. Tools Fit/Fitness/PHPFit (http://fit.c2.com/) (http://fitnesse.org/) (http://phpfit.berlios.de/)
  86. 86. Continuous Integration
  87. 87. Where? When? Run Automatic Tests
  88. 88. When?/Where? Unit Tests, Integration Tests, Database Tests, Acceptance Tests
  89. 89. When?/Where? (All Previous) + Smoke Tests
  90. 90. When?/Where? (All Previous) + Load/Performance/Security Tests + Migration/Installation/Configuration Tests
  91. 91. Test Automation Genesis
  92. 92. Risk Analysis
  93. 93. Brian Marick Cathegories Business Facing Support Programming Support Product Technology Facing
  94. 94. Brian Marick Cathegories Business Facing Support Programming Support Product Unit Tests Technology Facing
  95. 95. Brian Marick Cathegories Business Facing Support Programming Support Product Acceptance Tests Unit Tests Technology Facing
  96. 96. Brian Marick Cathegories Business Facing Support Programming Support Product Acceptance Tests Load/ Unit Security Tests Tests Technology Facing
  97. 97. Automatic Business Facing Support Programming Usability/ Support Product Acceptance Exploratory Tests Tests Load/ Unit Security/ Tests Tests Technology Facing
  98. 98. All Tests should be Automatic?
  99. 99. Manual Business Facing Support Programming Usability/ Support Product Acceptance Exploratory Tests Tests Load/ Unit Security/ Tests Tests Technology Facing
  100. 100. Manual Tests Drive Automatic Tests
  101. 101. Test Automation
  102. 102. Pay Attention to Test Automation
  103. 103. “An imperfect test today is better than a perfect test someday”
  104. 104. Test Automation = Process Improvement
  105. 105. Debug Sucks Test Rocks
  106. 106. Testing Web Applications Gabriele Lana www.gabrielelana.it info@gabrielelana.it

×