Gradle generates non-camel-cased multi-dimensional flavor build directories:

For example, I have a multidimensional flavor project

flavorDimensions 'dimenA', 'dimenB'

android {
    productFlavors {
        foo {
            dimension 'dimenA'
        }
        dev {
            dimension 'dimenB'
        }
    }
}

This means that If I wanted to access the full AndroidManifest.xml for the 
fooDev flavor, it will be at:

build/intermediates/manifests/full/foodev/debug/AndroidManifest.xml

However, Robolectric uses BuildConfig.FLAVOR to generate this, so it looks 
for the AndroidManifest file at:

build/intermediates/manifests/full/fooDev/debug/AndroidManifest.xml

My BuildConfig class:

public final class BuildConfig {
  public static final boolean DEBUG = Boolean.parseBoolean("true");
  public static final String APPLICATION_ID = "com.foo.test";
  public static final String BUILD_TYPE = "debug";
  public static final String FLAVOR = "fooDev";
  public static final int VERSION_CODE = 9500;
  public static final String VERSION_NAME = "9.5.0";
  public static final String FLAVOR_dimenA = "foo";
  public static final String FLAVOR_dimenB = "dev";
}

Should Robolectric not be only using just BuildConfig.FLAVOR to reference 
files? Or should the Android Gradle plugin generate build files with camel case 
build directories for multidimensional flavors? (i.e. creating build 
directories as fooDev instead of foodev)

-- 
You received this message because you are subscribed to the Google Groups 
"adt-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to