gerrit/gerrit-acceptance-framework
Dave Borowitz 96fe10508f ChangeRebuilderIT: Reopen ReviewDb when changing migration state
These tests commonly use methods on TestNotesMigration to play around
with the migration state. However, this wasn't taking into account
the fact that the migration state affects whether a ReviewDb opened
by the SchemaFactory is wrapped in a DisabledReviewDbChangesWrapper.

Unfortunately the request scope implementation used in tests caches
an open ReviewDb, meaning that depending on when the ReviewDb was
first opened, the cached value may be out of sync with the
TestNotesMigration state.

Work around this by always reopening the database, and ensuring the
returned Provider<ReviewDb> caches it as well, whenever the state
changes.

Change-Id: I1bfbbf5492f8232028eba969ace53cc659cb8c8b
2016-05-10 15:23:13 -07:00
..
src/test/java/com/google/gerrit/acceptance ChangeRebuilderIT: Reopen ReviewDb when changing migration state 2016-05-10 15:23:13 -07:00
BUCK Buck: Remove jgit cell 2016-04-20 22:02:49 +02:00
pom.xml Fix description in gerrit-acceptance-framework/pom.xml 2016-03-23 18:38:29 -04:00