 server = helpers.buildServer '../../api/resources/route',
   '../../data/route': routeData
 
-describe "util/api-key", ->
-  describe "api-key checking disabled", ->
+describe "lib/server", ->
+  describe "API key checking disabled", ->
     beforeEach ->
       process.env.RADBUS_API_KEYS_ENABLED = 'false'
     afterEach ->
       delete process.env.RADBUS_API_KEYS_ENABLED
 
-    it "#api-key disabled : should return 200 with the expected routes", ->
+    it "#API key disabled : should return 200 with the expected routes", ->
       request(server)
         .get('/routes')
         .json(true)

    it "should return 200 with the expected routes if API key is valid", ->
      request(server)
        .get('/routes')
        .headers('api-key': '4321')
        .json(true)
        .expect(200)
        .expect('Content-Type', /json/)

    it "should return 401 if the API key is invalid", ->
      r = request(server)
        .get('/routes')
        .headers('API-Key': 'bar-token')

      helpers.assert401WithInvalidApiKeyHeader r

