96fe10508f
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 |
||
---|---|---|
.. | ||
src/test/java/com/google/gerrit/acceptance | ||
BUCK | ||
pom.xml |