Patch to make flavor configuration for tests more flexible.