d3ee31c0cf
Override SystemReader to return empty files for the user and system config. This makes StandaloneNoteDbMigrationIT pass regardless of the configuration of the system it's running on. This has to happen in StandaloneSiteTest prior to site initialization, since the SystemReader is queried at FileRepository creation time, and Gerrit by design holds all created repos open in the RepositoryCache. If we tried to override the SystemReader in a test, it would have no effect, because the cached repos would already have the wrong config files loaded. Another complication is that GerritLauncher#mainImpl was creating a new classloader for every invocation, meaning the SystemReader class used by the wrapper code in StandaloneSiteTest was not the same class instance seen by the tests. Fix this by explicitly passing a ClassLoader when running. Change-Id: I478f3f712bced530c87b8fac3422275ec93d3557 |
||
---|---|---|
.. | ||
src/main/java/com/google/gerrit/launcher | ||
BUILD |