ListDelegationAdapter extends AbsDelegationAdapter<T> { @Override public int getItemCount() { return items == null ? 0 : items.size(); } ListDelegationAdapter();  ListDelegationAdapter(@NonNull AdapterDelegatesManager<T> delegatesManager);  ListDelegationAdapter(@NonNull AdapterDelegate<T>... delegates); @Override int getItemCount();  }
@Test public void checkNewAdapterDelegatesManagerInstanceNotNull() { ListDelegationAdapter<List<Object>> adapter = new ListDelegationAdapter<List<Object>>() { @Override public int getItemCount() { Assert.assertNotNull(this.delegatesManager); return 0; } }; adapter.getItemCount(); }
@Test public void checkDelegatesManagerInstance() { final AdapterDelegatesManager<List<Object>> manager = new AdapterDelegatesManager<>(); ListDelegationAdapter<List<Object>> adapter = new ListDelegationAdapter<List<Object>>(manager) { @Override public int getItemCount() { Assert.assertTrue(manager == this.delegatesManager); return 0; } }; adapter.getItemCount(); }