       worker_domain.dispose()
     worker_domain.once 'error', (err) => @_complete err  # only call complete once
     @reservation = new ReserveResource @constructor._name,
-      process.env.REDIS_HOST or null,
-      process.env.REDIS_PORT or null,
+      process.env.REDIS_HOST,
+      process.env.REDIS_PORT,
       @_hearbeat_interval,
       @_lock_ttl
     setImmediate =>

describe "redis-reservation", ->

  before (done) ->
    @redis = redis.createClient()  # localhost
    #@redis.select 3
    done()


        @redis.get 'reservation-test_resource', (err, resp) ->
          assert.equal resp, 'MOCK'
          done()

  it 'handles failing jobs', (done) ->
    @redis.set 'reservation-test_resource', 'MOCK', (err, resp) =>
      test_worker = new FailWorker resource_id: 'test_resource', (err, resp) =>
