JndiHelper { public static void bind(Collection<? extends AdaptrisComponent> components) throws CoreException { bind(createContext(), components, false); }  static String createJndiName(AdaptrisComponent object); static void bind(Collection<? extends AdaptrisComponent> components); static void bind(AdaptrisComponent adaptrisComponent); static void bind(Collection<? extends AdaptrisComponent> components, boolean debug); static void bind(AdaptrisComponent adaptrisComponent, boolean debug); static void bind(Context ctx, Collection<? extends AdaptrisComponent> components, boolean debug); static void bind(Context ctx, AdaptrisComponent component, boolean debug); static void unbind(Collection<? extends AdaptrisComponent> components); static void unbind(Collection<? extends AdaptrisComponent> components, boolean debug); static void unbind(AdaptrisComponent component, boolean debug); static void unbind(Context ctx, Collection<? extends AdaptrisComponent> components, boolean debug); static void unbind(Context ctx, AdaptrisComponent component, boolean debug); static void unbindQuietly(Context ctx, Collection<? extends AdaptrisComponent> components, boolean debug); static void unbindQuietly(Context ctx, AdaptrisComponent component, boolean debug);  }
@Test public void testBindNullTransactionManager() throws Exception { TransactionManager transactionManager = null; InitialContext initialContext = new InitialContext(env); try { JndiHelper.bind(initialContext, transactionManager, false); } catch (CoreException expected) { fail("Should not error, just ignore."); } }
@Test public void testBindNullTransactionManager_Debug() throws Exception { TransactionManager transactionManager = null; InitialContext initialContext = new InitialContext(env); try { JndiHelper.bind(initialContext, transactionManager, true); } catch (CoreException expected) { fail("Should not error, just ignore."); } }