Advertisement
Guest User

Untitled

a guest
May 19th, 2017
601
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.71 KB | None | 0 0
  1. function makeRequest(){
  2. const auth0BaseURL = Config.AUTH_URL
  3. const mock = { username: 'test03@222222.com', password: 'password!test', deviceTesting: true }
  4. const data = {'client_id': Config.AUTH_CLIENT, 'username': mock.username, 'password': mock.password, 'connection': '', 'device': 'testdevice', 'scope': ''}
  5. const api = apisauce.create({
  6. baseURL: authBaseURL,
  7. headers: {'content-type': 'application/json'},
  8. timeout: 100000
  9. })
  10. debugger
  11. var response = api.post('/auth/test', data, api.headers)
  12. debugger
  13. return response
  14. }
  15.  
  16. test('signup:Success', async t => {
  17. t.plan(1);
  18.  
  19. const res = await makeRequest()
  20. debugger
  21. t.is(res.status, 200);
  22. });
  23.  
  24.  
  25. Error: Promise returned by test never resolved\
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement