This project is read-only.

Design Meeting Notes - June 14, 2012

Making database connections in the test suite more configurable

Currently the vast majority of the EF6 tests only run against SQL Express. Some others are setup to also run against SQL Compact or LocalDb. In order to check things are working as expected against other backends it would be good if we could configure most tests to run against any type of database. The initial requirements for this are:

  • Check-in tests and main CI build should still run against SQL Express to provide fast check-in bar and CI feedback.
    • The run against other backends must happen frequently (at least once a day) but could be either triggered or scheduled.
  • We will still need some tests directed towards a specific backend (e.g. SQL Compact) where those tests are specifically designed to test behavior that is different for different database types.
    • In other cases the tests may be the same, but with backend-specific assertions such as is currently implemented for the Migrations tests.
  • The default for any new tests should be to run against any backend.
    • Attributes should be used to exclude a test from certain backends.
    • It should also be possible for assertions to be backend specific, as stated above.
  • The correct provider manifest token should be used for the backend in question. For example, it would be to use the 2005 manifest token when testing against 2008, but this should not be done.

We will schedule this work item for EF6. Some ideas on implementation:

  • As much as possible only functional tests should hit the database. Some unit tests currently hit the database—these should be investigated and changed/moved appropriately.
  • The Migrations/XUnit infrastructure is a good place to start for this, but will need significant modification to meet the requirements.

Last edited Dec 14, 2012 at 6:27 PM by ajcvickers, version 2