title: Mock FacesContext to test my faces message displayer class
body: <p>My Backing bean:</p>
  
  <pre><code>@ManagedBean(name = "messageDisplayer")
  @ViewScoped
  public class MessageDisplayer implements Serializable
  {
      private final Logger LOGGER = LoggerFactory.getLogger(this.getClass());
  
      public void showMessage (FacesMessage.Severity severity, String summary, String detail)
      {
          FacesContext context = FacesContext.getCurrentInstance();
          LOGGER.debug("Showing message with severity='{}', summary='{}', detail='{}'", severity, summary, detail);
          context.addMessage(null, new FacesMessage(severity, summary, detail));
      }
  }
  </code></pre>
  
  <p>Any help on how I can use Mockito to test this class!?</p>