           }
         }
         nock('https://api.pagerduty.com')
-        .get('/users?query=momo%40example.com')
+        .get('/users')
+        .query({
+          query: 'momo@example.com'
+        })
         .reply(200, require('./fixtures/users_list-nomatch.json'))
       afterEach ->
         room.robot.brain.data.pagerv2 = { }

      context 'when something goes wrong,', ->
        beforeEach ->
          nock('https://api.pagerduty.com')
          .get('/maintenance windows?filter=ongoing')
          .reply 503, { error: { code: 503, message: "it's all broken!" } }
        afterEach ->
          room.robot.brain.data.pagerv2 = { }

      context 'when something goes wrong,', ->
        beforeEach ->
          nock('https://api.pagerduty.com')
          .get('/services')
          .query({
            query: 'My Application Service'
          })
          .reply(200, require('./fixtures/services_list1-ok.json'))
          .get('/services')
          .query({
            query: 'Other Service'
          })
          .reply(200, require('./fixtures/services_list2-ok.json'))
          .post('/maintenance windows')
          .reply 503, { error: { code: 503, message: "it's all broken!" } }
