Skip to content
This repository has been archived by the owner on Feb 23, 2019. It is now read-only.
João Morais edited this page Sep 21, 2017 · 31 revisions

TODO

  • Start using templates for variable usage within strings, see here.

  • Review all unit tests and do memory related improvements like: stop using arrow functions and replace variable declaration by class properties where it makes sense / is possible, see here, here and here for related documentation.

  • Investigate the following:

    1. Metadata Handler generateFieldValue decimals should return a number with the proper number of digits: AssertionError: expected 4 to be at most 3 at Context.it (tests/metadata-handler.js:120:49) at Test.Runnable.run (node_modules/co-mocha/lib/co-mocha.js:43:16)
  • Investigate the following:

  1. Dashboards Accessing someone else's dashboard should not let a user delete another user's dashboard:

     TypeError: Cannot read property 'statusCode' of undefined       at . (node_modules/chakram/lib/assertions/statuscode.js:15:44)       at ctx.(anonymous function) (node_modules/chai/lib/chai/utils/addMethod.js:41:25)       at doAsserterAsyncAndAddThen (node_modules/chai-as-promised/lib/chai-as-promised.js:296:33)       at . (node_modules/chai-as-promised/lib/chai-as-promised.js:255:21)       at ctx.(anonymous function) [as status] (node_modules/chai/lib/chai/utils/overwriteMethod.js:49:33)       at Context. (modules/Dashboards/tests/rest/Dashboards.js:95:42)       at throw (native)       at onRejected (node_modules/co/index.js:81:24)       at _rejected (node_modules/q/q.js:844:24)       at node_modules/q/q.js:870:30       at Promise.when (node_modules/q/q.js:1122:31)       at Promise.promise.promiseDispatch (node_modules/q/q.js:788:41)       at node_modules/q/q.js:604:44       at runSingle (node_modules/q/q.js:137:13)       at flush (node_modules/q/q.js:125:13)       at _combinedTickCallback (internal/process/next_tick.js:67:7)       at process._tickCallback (internal/process/next_tick.js:98:9) ```

  • Investigate using expect(new Promise).to.be.a('promise') instead of isPromise(new Promise) in tests/index.js.

    1. The error that comes up when switching it out is: "Error: Some expectation promises were not fulfilled before the test finished. Ensure you are waiting for all the expectations to run"
  • Cache the metadata, especially for development. Maybe we should have a way to tell the metadata-fetcher to write the metadata out to a file, and another way to tell it to read from that file.

  • Split the index.js tests, as that file is becoming very large.

Clone this wiki locally