castor
  1. castor
  2. CASTOR-755

All unit tests for JDO should be placed in a new src/tests/utf/org/exolab/castor/ tree

    Details

    • Type: Improvement Improvement
    • Status: Closed Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 0.9.5.3
    • Fix Version/s: 0.9.9 M1
    • Component/s: JDO
    • Labels:
      None
    • Environment:
      Operating System: Linux
      Platform: PC
    • Bugzilla Id:
      1613
    • Number of attachments :
      2

      Description

      I have been thinking about writing a lot more unit level tests for things and
      I've been debating where these tests should live. I have come to the conclusion
      these tests will live in a newly creating directory structure beneath src/tests
      following the stand package hierarchy:

      src/test/org/exolab/castor/jdo/conf
      src/test/org/exolab/castor/jdo/drivers
      src/test/org/exolab/castor/jdo/engine
      src/test/org/exolab/castor/jdo/oql
      src/test/org/exolab/castor/jdo/transactionmanager
      src/test/org/exolab/castor/jdo/transactionmanager/spi
      src/test/org/exolab/castor/persist/
      src/test/org/exolab/castor/persist/cache
      src/test/org/exolab/castor/persist/spi

      I'm not sure what to do with the tests in src/tests/jdo yet. I think I'll just
      leave them there and continue to place functional tests there. If anyone has any
      suggestions, please speak up. I really like the TestHarness and the ability to
      run a functional test by specifying castor.postgresql.TC01. But the TestHarness
      is not necessary for unit level tests. Unit level tests should be able to run
      within a matter of seconds, should not require a database and should be run from
      within the Ant build. This is where mock objects come into play. Unit level
      tests should only test and verify the Castor functionality, not the database
      functionality and this is what differentiates a unit test from a functional test.

      1. patch-C755-1.txt
        32 kB
        Ralf Joachim
      2. patch-C755-20050731.txt
        73 kB
        Ralf Joachim

        Activity

        No work has yet been logged on this issue.

          People

          • Assignee:
            Ralf Joachim
            Reporter:
            Bruce Snyder (bugzilla)
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: