Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gulp unit:server is not working #81

Open
Stupidism opened this issue May 25, 2016 · 5 comments
Open

gulp unit:server is not working #81

Stupidism opened this issue May 25, 2016 · 5 comments

Comments

@Stupidism
Copy link
Collaborator

No description provided.

@Stupidism
Copy link
Collaborator Author

#63

@Stupidism
Copy link
Collaborator Author

  1) App should return with status 404 for an uncovered api route.:
     Error: timeout of 2000ms exceeded
    at Timeout.<anonymous> (/home/stupid/Documents/demos/material-app/node_modules/mocha/lib/runnable.js:158:19)
    at tryOnTimeout (timers.js:224:11)
    at Timer.listOnTimeout (timers.js:198:5)

@Stupidism
Copy link
Collaborator Author

  2) User Model should fail when saving a duplicate user:
     Uncaught AssertionError: expected null to exist

@Stupidism
Copy link
Collaborator Author

Stupidism commented May 25, 2016

This is because I add 404 not found for get put and delete method of ParamController

  3) param controller GET should return a document for its id:
     Error: expected 200 "OK", got 404 "Not Found"
  4) param controller PUT should update a document and respond with the updated document:
     Error: expected 200 "OK", got 404 "Not Found"
  5) param controller DELETE should delete a document and respond with 204:
     Error: expected 204 "No Content", got 404 "Not Found"

@Stupidism
Copy link
Collaborator Author

And before all these

GET /api/this/route/will/never/exist 404 2ms
[18:04:29] { [Error: unexpected end of file]
  errno: -5,
  code: 'Z_BUF_ERROR',
  domainEmitter: 
   Stream {
     domain: 
      Domain {
        domain: null,
        _events: [Object],
        _eventsCount: 1,
        _maxListeners: undefined,
        members: [],
        '__$cntxt__': {} },
     _events: { data: [Function], end: [Object] },
     _eventsCount: 2,
     _maxListeners: undefined,
     req: 
      ClientRequest {
        domain: [Object],
        _events: [Object],
        _eventsCount: 3,
        _maxListeners: undefined,
        output: [],
        outputEncodings: [],
        outputCallbacks: [],
        outputSize: 0,
        writable: true,
        _last: true,
        chunkedEncoding: false,
        shouldKeepAlive: false,
        useChunkedEncodingByDefault: false,
        sendDate: false,
        _removedHeader: {},
        _contentLength: 0,
        _hasBody: true,
        _trailer: '',
        finished: true,
        _headerSent: true,
        socket: [Object],
        connection: [Object],
        _header: 'GET /api/this/route/will/never/exist HTTP/1.1\r\nHost: 127.0.0.1:43761\r\nAccept-Encoding: gzip, deflate\r\nCookie: \r\nUser-Agent: node-superagent/0.18.0\r\nConnection: close\r\n\r\n',
        _headers: [Object],
        _headerNames: [Object],
        _onPendingData: null,
        agent: [Object],
        socketPath: undefined,
        method: 'GET',
        path: '/api/this/route/will/never/exist',
        parser: null,
        res: [Object] } },
  domain: 
   Domain {
     domain: null,
     _events: { error: [Function: handleException] },
     _eventsCount: 1,
     _maxListeners: undefined,
     members: [],
     '__$cntxt__': {} },
  domainThrown: false,
  name: 'Error',
  message: 'unexpected end of file',
  stack: 'Error: unexpected end of file\n  at Zlib._handle.onerror (zlib.js:370:17)\n',
  showStack: true,
  showProperties: true,
  plugin: 'gulp-mocha' }
[18:04:29] 'unit:server' errored after 562 ms
[18:04:29] Error in plugin 'gulp-mocha'

@Stupidism Stupidism changed the title gulp unit is not working gulp unit:server is not working May 27, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant