{"action":"created","issue":{"url":"https://api.github.com/repos/maidsafe/safe_core/issues/330","repository_url":"https://api.github.com/repos/maidsafe/safe_core","labels_url":"https://api.github.com/repos/maidsafe/safe_core/issues/330/labels{/name}","comments_url":"https://api.github.com/repos/maidsafe/safe_core/issues/330/comments","events_url":"https://api.github.com/repos/maidsafe/safe_core/issues/330/events","html_url":"https://github.com/maidsafe/safe_core/pull/330","id":176666054,"number":330,"title":"refactor/mock-routing: refactor mock routing","user":{"login":"madadam","id":5271,"avatar_url":"https://avatars.githubusercontent.com/u/5271?v=3","gravatar_id":"","url":"https://api.github.com/users/madadam","html_url":"https://github.com/madadam","followers_url":"https://api.github.com/users/madadam/followers","following_url":"https://api.github.com/users/madadam/following{/other_user}","gists_url":"https://api.github.com/users/madadam/gists{/gist_id}","starred_url":"https://api.github.com/users/madadam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/madadam/subscriptions","organizations_url":"https://api.github.com/users/madadam/orgs","repos_url":"https://api.github.com/users/madadam/repos","events_url":"https://api.github.com/users/madadam/events{/privacy}","received_events_url":"https://api.github.com/users/madadam/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"krishnaIndia","id":7702996,"avatar_url":"https://avatars.githubusercontent.com/u/7702996?v=3","gravatar_id":"","url":"https://api.github.com/users/krishnaIndia","html_url":"https://github.com/krishnaIndia","followers_url":"https://api.github.com/users/krishnaIndia/followers","following_url":"https://api.github.com/users/krishnaIndia/following{/other_user}","gists_url":"https://api.github.com/users/krishnaIndia/gists{/gist_id}","starred_url":"https://api.github.com/users/krishnaIndia/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/krishnaIndia/subscriptions","organizations_url":"https://api.github.com/users/krishnaIndia/orgs","repos_url":"https://api.github.com/users/krishnaIndia/repos","events_url":"https://api.github.com/users/krishnaIndia/events{/privacy}","received_events_url":"https://api.github.com/users/krishnaIndia/received_events","type":"User","site_admin":false},"assignees":[{"login":"krishnaIndia","id":7702996,"avatar_url":"https://avatars.githubusercontent.com/u/7702996?v=3","gravatar_id":"","url":"https://api.github.com/users/krishnaIndia","html_url":"https://github.com/krishnaIndia","followers_url":"https://api.github.com/users/krishnaIndia/followers","following_url":"https://api.github.com/users/krishnaIndia/following{/other_user}","gists_url":"https://api.github.com/users/krishnaIndia/gists{/gist_id}","starred_url":"https://api.github.com/users/krishnaIndia/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/krishnaIndia/subscriptions","organizations_url":"https://api.github.com/users/krishnaIndia/orgs","repos_url":"https://api.github.com/users/krishnaIndia/repos","events_url":"https://api.github.com/users/krishnaIndia/events{/privacy}","received_events_url":"https://api.github.com/users/krishnaIndia/received_events","type":"User","site_admin":false}],"milestone":null,"comments":5,"created_at":"2016-09-13T15:04:23Z","updated_at":"2016-09-15T12:39:29Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/maidsafe/safe_core/pulls/330","html_url":"https://github.com/maidsafe/safe_core/pull/330","diff_url":"https://github.com/maidsafe/safe_core/pull/330.diff","patch_url":"https://github.com/maidsafe/safe_core/pull/330.patch"},"body":"\n\n<!-- Reviewable:start -->\nThis change is [<img src=\"https://reviewable.io/review_button.svg\" height=\"34\" align=\"absmiddle\" alt=\"Reviewable\"/>](https://reviewable.io/reviews/maidsafe/safe_core/330)\n<!-- Reviewable:end -->\n"},"comment":{"url":"https://api.github.com/repos/maidsafe/safe_core/issues/comments/247316612","html_url":"https://github.com/maidsafe/safe_core/pull/330#issuecomment-247316612","issue_url":"https://api.github.com/repos/maidsafe/safe_core/issues/330","id":247316612,"user":{"login":"ustulation","id":8788153,"avatar_url":"https://avatars.githubusercontent.com/u/8788153?v=3","gravatar_id":"","url":"https://api.github.com/users/ustulation","html_url":"https://github.com/ustulation","followers_url":"https://api.github.com/users/ustulation/followers","following_url":"https://api.github.com/users/ustulation/following{/other_user}","gists_url":"https://api.github.com/users/ustulation/gists{/gist_id}","starred_url":"https://api.github.com/users/ustulation/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ustulation/subscriptions","organizations_url":"https://api.github.com/users/ustulation/orgs","repos_url":"https://api.github.com/users/ustulation/repos","events_url":"https://api.github.com/users/ustulation/events{/privacy}","received_events_url":"https://api.github.com/users/ustulation/received_events","type":"User","site_admin":false},"created_at":"2016-09-15T12:39:29Z","updated_at":"2016-09-15T12:39:29Z","body":"\n\n\n\n\n\n\n\n*[src/core/client/non_networking_test_framework/mod.rs, line 51 at r2](https://reviewable.io:443/reviews/maidsafe/safe_core/330#-KRh_27zz8gEW8CZNegM:-KRhmeoGKx9lAbOfB5Rr:b-daxtu) ([raw file](https://github.com/maidsafe/safe_core/blob/e79a25c8098bae1d99ac89189fdd78581c966f60/src/core/client/non_networking_test_framework/mod.rs#L51)):*\n<details><summary><i>Previously, madadam (Adam Cigánek) wrote…</i></summary>\n> That would break tests which create more than one session (and thus routing client) as they wouldn't be able to access each others data. Besides, the memory usage and speed benefits are questionable in my opinion. I'd say, it isn't worth the increased code complexity. \n</details>\n@madadam : Ah you are right about multisession tests - like create-account followed by login etc.\n\nBut speed benefits i still believe would be there - tests are run in parallel by cargo and a global mutex _will_ slow things down (they are held almost for entire of PUT/POST etc functions). With over 100 tests for `safe_core` it might soon become a bothersome waiting for all to pass on local machine as well as CI (it already take around 20-25 min per windows CI (thus over 40 min in total)) and that is in release.\n\nCan we not design something better here ? Like say `RoutingMock` constructor takes extra storage parameter in case of tests.  Since there are only 3 entry points to the api: `create_account`, `login` and `create_unregistered_account`, those could take extra parameter for tests to pass it to RoutingMock. For multisession tests then we can have:\n```\nlet storage: Arc<Mutex<Storage>>; // And pass storage.clone() to above. So same storage for the duration of the test\n```\nAnd other tests are not affected by any global mutex so run as parallel as cargo makes them.\n\nMaybe roughly record the difference in timings on running full test suite in release with current PR and something like above mentioned. Then if the difference is not significant we can drop the idea.\n\n---\n\n\n*Comments from [Reviewable](https://reviewable.io:443/reviews/maidsafe/safe_core/330)*\n<!-- Sent from Reviewable.io -->\n"}}
{"actor":{"display_login":"ustulation"}}