### Question:
ModuleSpec { public static ModuleSpec simple(final Class<? extends NativeModule> type) { return new ModuleSpec(type, new ConstructorProvider(type, EMPTY_SIGNATURE) { @Override public NativeModule get() { try { return getConstructor(type, EMPTY_SIGNATURE).newInstance(); } catch (Exception e) { throw new RuntimeException("ModuleSpec with class: " + type.getName(), e); } } }); } private  ModuleSpec(
      @Nullable Class<? extends NativeModule> type, Provider<? extends NativeModule> provider); static ModuleSpec simple(final Class<? extends NativeModule> type); static ModuleSpec simple(
      final Class<? extends NativeModule> type,
      final ReactApplicationContext context); static ModuleSpec viewManagerSpec(Provider<? extends NativeModule> provider); static ModuleSpec nativeModuleSpec(
      Class<? extends NativeModule> type, Provider<? extends NativeModule> provider); @Nullable Class<? extends NativeModule> getType(); Provider<? extends NativeModule> getProvider();  }### Answer:
@Test(expected = IllegalArgumentException.class) public void testSimpleFailFast() { Whitebox.setInternalState(ReactBuildConfig.class, "DEBUG", true); ModuleSpec.simple(ComplexModule.class, mock(ReactApplicationContext.class)); }
@Test(expected = IllegalArgumentException.class) public void testSimpleFailFastDefault() { Whitebox.setInternalState(ReactBuildConfig.class, "DEBUG", true); ModuleSpec.simple(ComplexModule.class); }
@Test public void testSimpleNoFailFastRelease() { Whitebox.setInternalState(ReactBuildConfig.class, "DEBUG", false); ModuleSpec.simple(ComplexModule.class, mock(ReactApplicationContext.class)); }