RTSD-Notes

Version 0.1 of slides are attached.

  1. Refactoring and Unit Testing in Sakai
    1. Point -> write code that is correct and easy to change
    2. Defns
      1. a)unit testing - logic testing
        b)integration testing - testing in context
        c)refactoring - change code organization (not functionality) for clarity, correctness and decoupling
    3. why Unit and Integration testing?
      a)Decoupled code
      b)clearer code
      c)testable code
    4. Why refactoring?
      a)Enable addition of features
      b)fix bugs
      c)avoid code terror
    5. combine and support each other
      a)refactor -> change
      b)change -> testing (errors)
      c)unit testing catches logic errors
      d)unit testing implies change code to be testable
      e)can't slap in UT since it requires code change (refactoring)
      f)can't slap in refactoring (change implies error)
      g)so put both in.
  2. Goals of talk
    introduce Unit testing, integration testing, and refactoring
    give example of doing it.
  3. Example
    1. SQL in Sakai is intertwined with code
    2. Hard to add new sql
      a)find a lot of spots to change
      b)change a lot of code in many places
      c)have to test changes in context of complete implementation
    3. Need to add new SQL
      a)tweaking (UMich needed to add something just for Oracle
      b)add new dialects
    4. Want to isolate SQL
      a)testing
      b)simply decouple code
    5. Event implementation
      1. refactor and unit test
        add some detail about code
        Do a walk through using Eclipse tools of:
        1. making method for the text
        2. extracting dialect logic into methods
        3. moving methods to separate class>
      2. integration test (Josh)

Ignore anything after this:

To run itests

  1. compile / deploy sakai into your standard maven.tomcat.home directory.
  2. setup _maven.tomcat.home/sakai/sakai.properties file (for hsqldb by default) necessary if want to use hsql?
  3. run maven itest goal with -Dmaven.test.skip=false
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.