summaryrefslogtreecommitdiff
path: root/test/letter-avatars.js
blob: 16197f52ab234161c955e6219f926b33d8221d6d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
/* eslint-env node, mocha */

'use strict'

const assert = require('assert')
const avatars = require('../lib/letter-avatars')

describe('generateAvatarURL()', function () {
  it('should return correct urls', function () {
    assert.strictEqual(avatars.generateAvatarURL('Daan Sprenkels', 'hello@dsprenkels.com', true), 'https://www.gravatar.com/avatar/d41b5f3508cc3f31865566a47dd0336b?s=400')
    assert.strictEqual(avatars.generateAvatarURL('Daan Sprenkels', 'hello@dsprenkels.com', false), 'https://www.gravatar.com/avatar/d41b5f3508cc3f31865566a47dd0336b?s=96')
  })
})