import tmiEmotes from 'web-client/utilities/tmi-emotes';
import { module, test } from 'qunit';

module('Unit | Utility | tmi emotes');

test('it returns emotes in the tmi format', function(assert) {
  let imEmotes = [
    {id: 25, start: 0, end: 4},
    {id: 88, start: 16, end: 23},
    {id: 25, start: 40, end: 44}
  ];

  let tmiFormat = tmiEmotes(imEmotes);
  assert.deepEqual(tmiFormat, {
    25: [[0,4], [40,44]],
    88: [[16,23]]
  });
});
