)]}'
{"src/index.js":[{"author":{"_account_id":8735,"name":"Vitaly Kramskikh","email":"vkramskikh@mirantis.com","username":"vkramskikh"},"change_message_id":"9dbf065d34620641fe794f6d2fbaf747f2673eba","unresolved":false,"context_lines":[{"line_number":1,"context_line":"import \u0027babel-polyfill\u0027;"},{"line_number":2,"context_line":"import \u0027isomorphic-fetch\u0027;"},{"line_number":3,"context_line":"import log from \u0027loglevel\u0027;"},{"line_number":4,"context_line":"import _ from \u0027underscore\u0027;"},{"line_number":5,"context_line":""},{"line_number":6,"context_line":"log.setLevel(\u0027INFO\u0027);"},{"line_number":7,"context_line":""}],"source_content_type":"text/javascript","patch_set":7,"id":"bacf61ea_f2a15faa","line":4,"updated":"2016-08-05 13:38:03.000000000","message":"Don\u0027t think adding a dependency to underscore is a good idea just to use _.has() because:\n\n1) It\u0027s not very good idea to add quite large library because of a single helper function\n2) LoDash may be a better candidate for utility library\n3) LoDash allows you to include a single helper (\"import has from \u0027lodash/has\u0027\") or use babel-lodash plugin which does treeshaking automatically, so the whole library won\u0027t be included in the resulting bundle","commit_id":"0fd84d9d5084d1e197ea96d85d724d747acfefe5"},{"author":{"_account_id":22670,"name":"Mitchell Smolash","email":"mitch@smolash.com","username":"msmol"},"change_message_id":"7a679702bab38910f7906b32ccdeda36546fa888","unresolved":false,"context_lines":[{"line_number":1,"context_line":"import \u0027babel-polyfill\u0027;"},{"line_number":2,"context_line":"import \u0027isomorphic-fetch\u0027;"},{"line_number":3,"context_line":"import log from \u0027loglevel\u0027;"},{"line_number":4,"context_line":"import _ from \u0027underscore\u0027;"},{"line_number":5,"context_line":""},{"line_number":6,"context_line":"log.setLevel(\u0027INFO\u0027);"},{"line_number":7,"context_line":""}],"source_content_type":"text/javascript","patch_set":7,"id":"bacf61ea_55dace17","line":4,"in_reply_to":"bacf61ea_f2a15faa","updated":"2016-08-05 15:41:45.000000000","message":"Ok, I\u0027ll remove underscore for now and use hasOwnproperty, we can discuss underscore/lodash/etc. at the next meeting","commit_id":"0fd84d9d5084d1e197ea96d85d724d747acfefe5"},{"author":{"_account_id":8735,"name":"Vitaly Kramskikh","email":"vkramskikh@mirantis.com","username":"vkramskikh"},"change_message_id":"9dbf065d34620641fe794f6d2fbaf747f2673eba","unresolved":false,"context_lines":[{"line_number":5,"context_line":""},{"line_number":6,"context_line":"log.setLevel(\u0027INFO\u0027);"},{"line_number":7,"context_line":""},{"line_number":8,"context_line":"export default class Keystone {"},{"line_number":9,"context_line":""},{"line_number":10,"context_line":"  constructor(cloudsConfig, cloudName) {"},{"line_number":11,"context_line":"    if (_.has(cloudsConfig.clouds, cloudName)) {"}],"source_content_type":"text/javascript","patch_set":7,"id":"bacf61ea_f2dddf14","line":8,"updated":"2016-08-05 13:38:03.000000000","message":"I believe a separate file should be created for keystone client. Index file probably should just import and export clients and contain no other logic.","commit_id":"0fd84d9d5084d1e197ea96d85d724d747acfefe5"}],"test/unit/indexTest.js":[{"author":{"_account_id":22670,"name":"Mitchell Smolash","email":"mitch@smolash.com","username":"msmol"},"change_message_id":"d5eec9255895025d074bea871fe0f1093c81e944","unresolved":false,"context_lines":[{"line_number":42,"context_line":"    const keystone \u003d new Keystone(configJson, cloudName);"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"    keystone.authenticate()"},{"line_number":45,"context_line":"      .then(() \u003d\u003e {"},{"line_number":46,"context_line":"        expect(fetchMock.called(auth_url)).toEqual(true);"},{"line_number":47,"context_line":"        expect(typeof keystone.token).toEqual(\u0027string\u0027);"},{"line_number":48,"context_line":"        expect(keystone.token).toEqual(\u0027the-token\u0027);"}],"source_content_type":"text/javascript","patch_set":1,"id":"bacf61ea_ee4c8978","line":45,"updated":"2016-07-27 20:11:14.000000000","message":"`.then` is being called, but the expectations are all failing. fetch-mock is not set up properly and is not intercepting the calls.","commit_id":"8aed652e2d5413da985555ed80c76ca3f440eacc"},{"author":{"_account_id":8735,"name":"Vitaly Kramskikh","email":"vkramskikh@mirantis.com","username":"vkramskikh"},"change_message_id":"9dbf065d34620641fe794f6d2fbaf747f2673eba","unresolved":false,"context_lines":[{"line_number":1,"context_line":"/*eslint no-unused-vars: \"off\"*/"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"import Keystone from \u0027../../src/index.js\u0027;"},{"line_number":4,"context_line":"import fetchMock from \u0027fetch-mock\u0027;"}],"source_content_type":"text/javascript","patch_set":7,"id":"bacf61ea_d2bb7bc2","line":1,"range":{"start_line":1,"start_character":0,"end_line":1,"end_character":32},"updated":"2016-08-05 13:38:03.000000000","message":"It seems this is needed just for line 17. You can declare the keystone var earlier or not to use it at all.","commit_id":"0fd84d9d5084d1e197ea96d85d724d747acfefe5"},{"author":{"_account_id":22670,"name":"Mitchell Smolash","email":"mitch@smolash.com","username":"msmol"},"change_message_id":"7a679702bab38910f7906b32ccdeda36546fa888","unresolved":false,"context_lines":[{"line_number":1,"context_line":"/*eslint no-unused-vars: \"off\"*/"},{"line_number":2,"context_line":""},{"line_number":3,"context_line":"import Keystone from \u0027../../src/index.js\u0027;"},{"line_number":4,"context_line":"import fetchMock from \u0027fetch-mock\u0027;"}],"source_content_type":"text/javascript","patch_set":7,"id":"bacf61ea_35a75aa8","line":1,"range":{"start_line":1,"start_character":0,"end_line":1,"end_character":32},"in_reply_to":"bacf61ea_d2bb7bc2","updated":"2016-08-05 15:41:45.000000000","message":"Several problems:\n1. Not declaring the variable results in `error  Do not use \u0027new\u0027 for side effects  no-new` linting error\n2. Declaring the variable earlier and setting it inside the try doesn\u0027t solve the issue, it\u0027s still seen as an unused variable\n\nTwo solutions I see: \n1. Use this eslint exception\n2. Use the variable even though the line will never be reached (e.g. call `keystone.authenticate()`) since the constructor will throw an exception","commit_id":"0fd84d9d5084d1e197ea96d85d724d747acfefe5"}]}
