mjackson/then-redis

View on GitHub
modules/__tests__/ready-flag-test.js

Summary

Maintainability
A
3 hrs
Test Coverage
import expect from 'expect'
import redis from '../index'

describe('ready-flag', () => {
  let client
  beforeEach(() => {
    client = redis.createClient()
  })

  it('is set on ready', (done) => {
    client.on('ready', () => {
      expect(client.ready).toEqual(true)
      done()
    })
  })
})