 
     queue = [
 
-      ->
+      (next) ->
         # expecting username that has less then minimum character length to return 400
         validateUsernameRequestParams = generateValidateUsernameRequestParams
           body       :


        expectedBody = JSON.stringify { kodingUser : false, forbidden : true }
        request.post validateUsernameRequestParams, (err, res, body) ->
          expect(err)             .to.not.exist
          expect(res.statusCode)  .to.be.equal 400
          expect(body)            .to.be.equal expectedBody
          queue.next()

      ->
        # expecting username that has more than maximum character length to return 400
        validateUsernameRequestParams = generateValidateUsernameRequestParams
          body       :


        expectedBody = JSON.stringify { kodingUser : false, forbidden : true }
        request.post validateUsernameRequestParams, (err, res, body) ->
          expect(err).to.not.exist
          expect(res.statusCode).to.be.equal 400
          expect(body).to.be.equal expectedBody
          next()

    ]

    async.series queue, done


  it 'should send HTTP 200 if username is not in use, not forbidden, has valid range', (done) ->
