joshbalfour / node-cognitive-services

Microsoft® Cognitive Services SDK for Node.JS
https://www.microsoft.com/cognitive-services
MIT License
105 stars 45 forks source link

REST dry #44

Closed v-geberr closed 6 years ago

miparnisari commented 6 years ago

I get this when running the tests:

  25 passing (2m)
  3 failing

  1) Language understanding (LUIS) Delete app after should import app:
     AssertionError: expected 'https://westus.api.cognitive.microsoft.com/luis/api/v2.0/apps/13b43d7d-cedc-4ad1-9de8-d8b3ae91ed2b' to have property length of 70 (got 98)
      at Assertion.fail (node_modules\should\cjs\should.js:275:17)
      at Assertion.value (node_modules\should\cjs\should.js:356:19)
      at promiseDelay.then.then (test\language\languageUnderstandingTest.js:241:54)
      at <anonymous>

  2) Language understanding (LUIS) Delete app after "after each" hook for "should import app":
     StatusCodeError: 400 - {"Message":"The request is invalid."}
      at new StatusCodeError (node_modules\request-promise-core\lib\errors.js:32:15)
      at Request.plumbing.callback (node_modules\request-promise-core\lib\plumbing.js:104:33)
      at Request.RP$callback [as _callback] (node_modules\request-promise-core\lib\plumbing.js:46:31)
      at Request.self.callback (node_modules\request\request.js:186:22)
      at Request.<anonymous> (node_modules\request\request.js:1163:10)
      at IncomingMessage.<anonymous> (node_modules\request\request.js:1085:12)
      at endReadableNT (_stream_readable.js:1056:12)
      at _combinedTickCallback (internal/process/next_tick.js:138:11)
      at process._tickDomainCallback (internal/process/next_tick.js:218:9)

  3) Language understanding (LUIS) Create app before, delete app after "after all" hook:
     Uncaught 2 tests failed.

events.js:183
      throw er; // Unhandled 'error' event
      ^
Error: 3 tests failed.
miparnisari commented 6 years ago

I still get the same errors :(

dfberry commented 6 years ago

On a clean clone and pull of the PR, the only errors I get are 429 too many requests. I can fix that. What exactly are the errors you are seeing? Are you on a clean clone of the PR?

miparnisari commented 6 years ago

Hey, I ran the tests and they passed. Can you apply this patch with some minor jshint fixes? Then I'll merge. patch.zip