Live Testing a Legacy App

Live Testing a Legacy App

Used in combination with https://github.com/elpete/testing-legacy-cfml

This presentation goes through the basics of the different types of testing and then explores Selenium testing with TestBox as the first step to testing a legacy application.

Cbddee54e0016667b9bcb0fdec4ab21e?s=128

Eric Peterson

June 16, 2016
Tweet

Transcript

  1. LIVE TESTING A LEGACY APP

  2. WHAT THIS TALK ISN'T ! > About TDD > Framework

    Specific > For testing veterans
  3. WHAT THIS TALK IS ! > An introduction to testing

    jargon > A collection of techniques for starting to test your app > Introduction to Selenium and TestBox > Asking tough questions as well as giving answers
  4. OTHER SESSIONS RIGHT NOW > Lucee Panel Discussion — Room

    235 > Writing Highly Organized CSS — Room 238 > Ouch, It Hurst When Do That. A Tale Of Landmines And Self-Inflicted Wounds — Room 321 > Getting Started With Build Tools — Auditorium
  5. WHO AM I? ERIC PETERSON ! Utah " O.C. Tanner

    # 1 wife, 1 kid
  6. WHAT KIND OF THINGS MAKE AN APP A LEGACY APP?

    > No framework > Few or no tests > Old or incorrect design decisions > New or changed business requirements
  7. NO TESTS CONTRIBUTE TO A LEGACY APP? ABSOLUTELY!

  8. WHY? THEY MAKE US SLOWER

  9. HERE'S THE DEAL EVERYBODY TESTS MODERN CODE WORKS TO AUTOMATE

    IT
  10. TYPES OF TESTING > Unit Tests > Integrated Tests >

    Functional Tests > Application Tests > End-to-end Tests
  11. TYPES OF TESTING (CONTINUED...) > Regression Tests > Acceptance Tests

    > Performance Tests > Accessibility Tests > Compatibility Tests
  12. STOP!!! !

  13. MY LEGACY APP TESTING PHILOSOPHY* (* SUBJECT TO CONSTANT CHANGE

    !) > Don't stress about the kinds of tests you are writing. Slow tests are better than no tests > Utilize Continuous Integration to offset this > Split your tests up and create multiple runners to help as well.
  14. MY TESTING PHILOSOPHY TEST WHAT MAKES SENSE (AND WHAT SAVES

    YOU MONEY) SOME EXAMPLES: > It broke before > We test it manually every time > The logic is kind of hard to follow (for the next time
  15. MY TESTING PHILOSOPHY TDD > Helps you design the class

    one piece at a time (not focused on in this talk) > Pair programming (one writes the test, the other writes the code to make the test pass)
  16. BEST TYPES OF TESTS FOR A LEGACY APP? Integration Testing

    & Regression Testing
  17. BEST TOOLS TO TEST A LEGACY APP? > Selenium >

    TestBox > Travis
  18. TESTING GOTCHAS (FOR LEGACY APPS) > Be careful of mocks

    > Don't test too many details
  19. DEMO THE LEGACY APP

  20. DEMO INTEGRATED TEST (SELENIUM)

  21. DEMO UNIT TEST

  22. DEMO REFACTORING

  23. LAST NOTE CONTINUOUS INTEGRATION Travis CI & CFML CI

  24. None
  25. LAST NOTE CONTINUOUS INTEGRATION > Emails > Github Badges >

    Slack Integration
  26. LAST NOTE CONTINUOUS INTEGRATION USE WITH MULTIPLE TESTBOX RUNNERS.

  27. THANK YOU!! elpete @_elpete ! dev.elpete.com