alert first two notifications&#39;, function() {
  notify(&#39;one&#39;);
  notify(&#39;two&#39;);

  expect(mock.alert).not.toHaveBeenCalled();
});

it(&#39;should alert all after third notification&#39;, function() {
  notify(&#39;one&#39;);
  notify(&#39;two&#39;);
  notify(&#39;three&#39;);

  expect(mock.alert).toHaveBeenCalledWith(&quot;one\ntwo\nthree&quot;);
});

it(&#39;should clear messages after alert&#39;, function() {
  notify(&#39;one&#39;);
  notify(&#39;two&#39;);
  notify(&#39;third&#39;);
