Skip to content

Instantly share code, notes, and snippets.

@profOnno
Last active November 10, 2015 22:07
Show Gist options
  • Select an option

  • Save profOnno/e627cb1ec98a001b2289 to your computer and use it in GitHub Desktop.

Select an option

Save profOnno/e627cb1ec98a001b2289 to your computer and use it in GitHub Desktop.
pump.io test

Upgrading dependencies:

  • Showdown: From github: Breaking Changes

    NAMESPACE: showdown's namespace changed.

    To migrate your code you should update all references to Showdown with showdown.

    Converter: converter reference changed from converter to Converter.

    To migrate you should update all references to Showdown.converter with showdown.Converter

I changed the noweb code (in lib/app.js).

connect-databank

Middleware stuff has changed using : https://github.com/tj/connect-redis as inspiration note the error part for later...

  • trying to hook to a on disconnect. to clean timers stuff.. works from test but not from connect-databank!?

New version 'new' problems

info

  • npm 2.11.3
  • node v0.12.7 (used nvm to install it)
  • vows 0.8.1

setup stuff

  • Changed the qs version of connect ..(node_module/connect/package.json) fixed it to 5.2.0.
  • Changed zombie version to 3.x.x

problem stuf

  • test/lib/oauth.js setupApp hanging... fixed? by changing kill() to kill(SIGKILL)
  • lib/app.js hanging... connect_databank is not cleaning up.. needs fixing... for now I did set cleanupInterval = false, to keep going... there is a setTimout that needs to be cleared
  • zombie, need .close() after browser has done his job. Zombie changed in in versions... so did the calls zombie doen't return the browser object after the visit, and uses
  • restricted-post-test.js, oauthjsonerror but not always, error is alway there but vows doesn't always get it. (maybe to do with cleanupInterval?, gets oathjsonerror on occasion... (test oath-evan stuff?) and allways in different vows, parallel stuff? results in wrong order? after last postJSON there should be 10 no error callbacks and then 8 error callbacks and rest noerrors
  • schema-test line 86, does weird with vows (but tests ok?);
  • test/oauth-parrallel-access-token-test.js doen't always work, seems to be timeout in clientside stuff.., the problem should be fixed in test/lib/oauth.js where the browser stuff is set maxDelay ore something in zombie({});
  • homepage-noweb-test??? see pump-test-work3.md ... fixing dependancie stuff.

zombie

  • needs zombie.close();
  • to make it real nice wait for the close to finish:
teardown: function(browser){
  Step(
      function(){
          browser.on("closed",this);
          browser.close();
      },
      function(){
          console.log("done closing");
      }
  );
}
  • zombie.assert.success() and zombie.assert.text("element#id","hello");
  • old asser zombie.query still works... so zombie.assert is not needed!? choice to be made.

still some stuff todo

  • showdown wants update
  • set-immediate needs to be setimmediate... tried... but then tests fail again.

If tests fail?

  • vows hangs... should be fixed but not really priority

Getting vows working...

Machine info

  • npm 1.3.10
  • node v0.10.25
  • vows 0.7.0 (i think)
  • ubuntu 14.04 server

issue list:

  • FIXED shared-library-test lingers.. keeps port open? use http.get with agent:false; else not all http.gets (if req >1) get closed

  • FIXED oauth-parallel-access-token-tst (errors are still there but come from zombie public clientside javascript, returns valid stuf to the server though)

  • FIXED filteredstream-test.js cant use 'location' as variable name

  • FIXED app-test.js lingers; 2x app-test.js fails (can't do two of the same tests (vows test.js test.js) in this vows version)

  • FIXED application-test.js then app-test.js fails

  • FIXED app-test.js then application-test is ok

  • FIXED email-notification.js - needs a patch to rai.js (smtpclient raiserver stuff)

  • FIXED lrdd-test.js fails on having no lrdd end point, order of adding endpoints to express matters (2 files use 'api/')

  • FIXED oauth-request-token-test.js lingers, 'Wrapped Range' not supported (zombie clientside console stuff).

  • X user-restxxxx.js ?

  • SEMIFIX regiters-web-ui-tst.js (skip thrown Errors on ClientSide script, but does check 200 OK response (= user registerd);

  • as-root remote-group, proxy-url, host-test-as-root

part II

  • proxy pump trough another, util.pump() is deprecated. use readableStream.pipe()
  • noweb test WrappedRange ..exception

minor stuff

  • adding note in test that stream interface takes a long time
  • adding note in test... 5000 remove one... that it takes some time.
  • typo in lib/model/stream.js line 351 err2 and err used

notes

vows wait for port to be free in tearup connect to port? to test req=http.get() req.on("error"){}; to make vows happy fix test/lib/xrd //no new Error() oh it shoud work with new Error //revert http.get(options, function(ONEARG){}); //so testcase is wrong in expecting (err,res)

todo

update timerstore pverwrite clearTimeout & clearInterval test for app.on("close"); if overwritten....

-rw-rw-r-- 1 vagrant vagrant  5946 Oct 27 19:07 test/email-notification-tst.js
-rw-r--r-- 1 vagrant vagrant 27113 Oct 24 23:20 test/filteredstream-tst.js
-rw-r--r-- 1 vagrant vagrant  7000 Oct 27 20:46 test/lrdd-tst.js
-rw-r--r-- 1 vagrant vagrant  3666 Oct 25 11:15 test/oauth-parallel-access-token-tst.js
-rw-r--r-- 1 vagrant vagrant  5317 Oct 25 11:26 test/plugin-tst.js
-rw-r--r-- 1 vagrant vagrant  4694 Oct 24 14:38 test/register-web-ui-tst.js
-rw-r--r-- 1 vagrant vagrant  2471 Oct 24 14:38 test/shared-library-tst.js
@profOnno
Copy link
Author

profOnno commented Nov 7, 2015

only for node 0.10.x ...and the debian apt-get nodejs version is not working.
added a .md for version 0.12.x (wil probably fix some hidden 0.10.x stuff)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment