ProjectAdapter extends RecyclerView.Adapter<ProjectAdapter.ViewHolder> { @Override public int getItemCount() { return projects.size(); } ProjectAdapter(List<Project> projects, FragmentManager fragmentManager); @Override int getItemViewType(int position); @Nullable @Override ViewHolder onCreateViewHolder(ViewGroup parent, int viewType); @Override void onBindViewHolder(ViewHolder holder, int position); @Override int getItemCount(); static final String STATUS_SUCCESS; static final String STATUS_FAILURE; static final String STATUS_UNKNOWN; static final String ACTIVITY_BUILDING; }
@Test public void getItemCount() throws Exception { assertThat(adapter.getItemCount()).isEqualTo(1); }