VitaminSaber { public static void inject(Activity target) { inject(target, target, ResourceFinder.CONTEXT); } private  VitaminSaber(); static void setDebug(boolean debug); static void inject(Activity target); static void inject(Fragment target); static void inject(Context context, Object target); @SuppressWarnings({ "unchecked", "UnusedDeclaration" }) // Checked by runtime cast. Public API. static T get(Bundle bundle, String key);  }
@Test public void zeroInjectionsInjectDoesNotThrowException() { class Example { } Example example = new Example(); VitaminSaber.inject(null, example, null); assertThat(VitaminSaber.INJECTORS).contains(entry(Example.class, VitaminSaber.NO_OP)); }
@Test public void injectingKnownPackagesIsNoOp() { VitaminSaber.inject(new Activity()); assertThat(VitaminSaber.INJECTORS).isEmpty(); VitaminSaber.inject(new Activity(), new Object()); assertThat(VitaminSaber.INJECTORS).isEmpty(); }