### Question:
AwardRenderer implements ModelRenderer<Award, AwardRenderer.RenderArgs> { @Override public @Nullable ListElement renderFromModel(Award award, RenderArgs args) { switch (args.renderType) { case RENDER_CARDED: return new CardedAwardListElement( mDatafeed, award.getName(), award.getEventKey(), award.getRecipientList(), args.teams, args.selectedTeamKey); } return null; } @Inject  AwardRenderer(APICache datafeed); @Override @Nullable ListElement renderFromKey(String key, ModelType type, RenderArgs args); @Override @Nullable ListElement renderFromModel(Award award, RenderArgs args); static final int RENDER_CARDED; }### Answer:
@Test public void testRenderIndividualCarded() { Award award = ModelMaker.getModel(Award.class, AWARD_INDIVIDUAL); ListItem rendered = mRenderer.renderFromModel(award, new AwardRenderer.RenderArgs(new HashMap<>(), null)); assertNotNull(rendered); assertTrue(rendered instanceof CardedAwardListElement); }
@Test public void testRenderTeamCarded() { Award award = ModelMaker.getModel(Award.class, AWARD_TEAM); ListItem rendered = mRenderer.renderFromModel(award, new AwardRenderer.RenderArgs(new HashMap<>(), null)); assertNotNull(rendered); assertTrue(rendered instanceof CardedAwardListElement); }