1

I have a application in node.js and swagger which queries looker for the data,I am able to run the basic unit test cases. When I need to test the queries which hit looker(which is running in other server) I have to start my node service and then query the looker. In my local machine I am able to start the service in one terminal tab(npm app)and start the test cases from other tab(npm test) but I am not able to do the same thing when I deploy it to GitHub repository, Is there any other way around through which it can be done or any way that I can mock the looker call(which is a api call) and run it so I don't have to start my service in the repository.

Katie Hurley
  • 179
  • 9
user3649361
  • 944
  • 4
  • 20
  • 40
  • If you're trying to run some API calls, you'll need a Looker instance to send them to. You'll need to either spin up a new Looker instance, or configure your local app to point to the instance your prod is using. Since Looker generally doesn't write to the DB, it shouldn't interfere with prod as long as you're careful about clearing cache and building PDTs. – Will Aug 08 '17 at 16:26

1 Answers1

1

I found a solution to this, I was able to mock the api request using NOCK

user3649361
  • 944
  • 4
  • 20
  • 40