{"action":"created","comment":{"url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/pulls/comments/65699254","id":65699254,"diff_hunk":"@@ -0,0 +1,266 @@\n+var expect = require(\"chai\").expect;\n+var HazelcastClient = require(\"../.\").Client;\n+var Controller = require('./RC');\n+var Util = require('./Util');\n+\n+describe(\"List Proxy\", function () {\n+\n+    var cluster;\n+    var client;\n+    var listInstance;\n+\n+    before(function () {\n+        this.timeout(10000);\n+        return Controller.createCluster().then(function (response) {\n+            cluster = response;\n+            return Controller.startMember(cluster.id);\n+        }).then(function () {\n+            return HazelcastClient.newHazelcastClient().then(function (hazelcastClient) {\n+                client = hazelcastClient;\n+            });\n+        });\n+    });\n+\n+    beforeEach(function () {\n+        listInstance = client.getList('test')\n+    });\n+\n+    afterEach(function () {\n+        return listInstance.destroy();\n+    });\n+\n+    after(function () {\n+        client.shutdown();\n+        return Controller.shutdownCluster(cluster.id);\n+    });\n+\n+\n+    it(\"appends one item\", function () {\n+        return listInstance.add(1).then(function () {\n+            return listInstance.size().then(function (size) {\n+                expect(size).to.equal(1);\n+            });\n+        })\n+    });\n+\n+    it(\"inserts one item at index\", function () {\n+        return listInstance.addAll([1, 2, 3]).then(function () {\n+            return listInstance.addAt(1, 5).then(function (size) {\n+                return listInstance.toArray();\n+            }).then(function (all) {\n+                expect(all).to.deep.equal([1, 5, 2, 3]);\n+            });\n+        })\n+    });\n+\n+    it(\"clears\", function () {\n+        return listInstance.addAll([1, 2, 3]).then(function () {\n+            return listInstance.clear();\n+        }).then(function () {\n+            return listInstance.size().then(function (size) {\n+                expect(size).to.equal(0);\n+            });\n+        });\n+    });\n+\n+\n+    it(\"inserts all elements of array at index\", function () {\n+        return listInstance.addAll([1, 2, 3]).then(function () {\n+            return listInstance.addAllAt(1, [5, 6]);\n+        }).then(function () {\n+            return listInstance.toArray();\n+        }).then(function (all) {\n+            expect(all).to.deep.equal([1, 5, 6, 2, 3])\n+        });\n+    });\n+\n+\n+    it(\"gets item at index\", function () {\n+        var input = [1, 2, 3];\n+        return listInstance.addAll(input).then(function () {\n+            return listInstance.get(1).then(function (result) {\n+                expect(result).to.equal(2);\n+            });\n+        });\n+    });\n+\n+    it(\"removes item at index\", function () {\n+        var input = [1, 2, 3];\n+        return listInstance.addAll(input).then(function () {\n+            return listInstance.removeAt(1).then(function (replaced) {\n+                expect(replaced).to.equal(2);\n+            });\n+        }).then(function () {\n+            return listInstance.toArray().then(function (all) {\n+                expect(all).to.deep.equal([1, 3]);\n+            });\n+        });\n+    });\n+\n+    it(\"replaces item at index\", function () {","path":"test/ListProxyTest.js","position":100,"original_position":100,"commit_id":"be6f6a26ca8cb6bf3050146e9d3fc8d0c2885e5e","original_commit_id":"be6f6a26ca8cb6bf3050146e9d3fc8d0c2885e5e","user":{"login":"mustafaiman","id":6582349,"avatar_url":"https://avatars.githubusercontent.com/u/6582349?v=3","gravatar_id":"","url":"https://api.github.com/users/mustafaiman","html_url":"https://github.com/mustafaiman","followers_url":"https://api.github.com/users/mustafaiman/followers","following_url":"https://api.github.com/users/mustafaiman/following{/other_user}","gists_url":"https://api.github.com/users/mustafaiman/gists{/gist_id}","starred_url":"https://api.github.com/users/mustafaiman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mustafaiman/subscriptions","organizations_url":"https://api.github.com/users/mustafaiman/orgs","repos_url":"https://api.github.com/users/mustafaiman/repos","events_url":"https://api.github.com/users/mustafaiman/events{/privacy}","received_events_url":"https://api.github.com/users/mustafaiman/received_events","type":"User","site_admin":false},"body":"This test is also hard to read.","created_at":"2016-06-03T12:33:09Z","updated_at":"2016-06-03T12:33:10Z","html_url":"https://github.com/hazelcast/hazelcast-nodejs-client/pull/108#discussion_r65699254","pull_request_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/pulls/108","_links":{"self":{"href":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/pulls/comments/65699254"},"html":{"href":"https://github.com/hazelcast/hazelcast-nodejs-client/pull/108#discussion_r65699254"},"pull_request":{"href":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/pulls/108"}}},"pull_request":{"url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/pulls/108","id":72491798,"html_url":"https://github.com/hazelcast/hazelcast-nodejs-client/pull/108","diff_url":"https://github.com/hazelcast/hazelcast-nodejs-client/pull/108.diff","patch_url":"https://github.com/hazelcast/hazelcast-nodejs-client/pull/108.patch","issue_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/issues/108","number":108,"state":"open","locked":false,"title":"List implementation","user":{"login":"GhostInAMachine","id":11163575,"avatar_url":"https://avatars.githubusercontent.com/u/11163575?v=3","gravatar_id":"","url":"https://api.github.com/users/GhostInAMachine","html_url":"https://github.com/GhostInAMachine","followers_url":"https://api.github.com/users/GhostInAMachine/followers","following_url":"https://api.github.com/users/GhostInAMachine/following{/other_user}","gists_url":"https://api.github.com/users/GhostInAMachine/gists{/gist_id}","starred_url":"https://api.github.com/users/GhostInAMachine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GhostInAMachine/subscriptions","organizations_url":"https://api.github.com/users/GhostInAMachine/orgs","repos_url":"https://api.github.com/users/GhostInAMachine/repos","events_url":"https://api.github.com/users/GhostInAMachine/events{/privacy}","received_events_url":"https://api.github.com/users/GhostInAMachine/received_events","type":"User","site_admin":false},"body":"Interface fixes","created_at":"2016-06-03T11:21:51Z","updated_at":"2016-06-03T12:33:10Z","closed_at":null,"merged_at":null,"merge_commit_sha":"967f51b41a22bb38451d5809d9059aa5cbb042b1","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/pulls/108/commits","review_comments_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/pulls/108/comments","review_comment_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/pulls/comments{/number}","comments_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/issues/108/comments","statuses_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/statuses/be6f6a26ca8cb6bf3050146e9d3fc8d0c2885e5e","head":{"label":"GhostInAMachine:List_Impl","ref":"List_Impl","sha":"be6f6a26ca8cb6bf3050146e9d3fc8d0c2885e5e","user":{"login":"GhostInAMachine","id":11163575,"avatar_url":"https://avatars.githubusercontent.com/u/11163575?v=3","gravatar_id":"","url":"https://api.github.com/users/GhostInAMachine","html_url":"https://github.com/GhostInAMachine","followers_url":"https://api.github.com/users/GhostInAMachine/followers","following_url":"https://api.github.com/users/GhostInAMachine/following{/other_user}","gists_url":"https://api.github.com/users/GhostInAMachine/gists{/gist_id}","starred_url":"https://api.github.com/users/GhostInAMachine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GhostInAMachine/subscriptions","organizations_url":"https://api.github.com/users/GhostInAMachine/orgs","repos_url":"https://api.github.com/users/GhostInAMachine/repos","events_url":"https://api.github.com/users/GhostInAMachine/events{/privacy}","received_events_url":"https://api.github.com/users/GhostInAMachine/received_events","type":"User","site_admin":false},"repo":{"id":47989854,"name":"hazelcast-nodejs-client","full_name":"GhostInAMachine/hazelcast-nodejs-client","owner":{"login":"GhostInAMachine","id":11163575,"avatar_url":"https://avatars.githubusercontent.com/u/11163575?v=3","gravatar_id":"","url":"https://api.github.com/users/GhostInAMachine","html_url":"https://github.com/GhostInAMachine","followers_url":"https://api.github.com/users/GhostInAMachine/followers","following_url":"https://api.github.com/users/GhostInAMachine/following{/other_user}","gists_url":"https://api.github.com/users/GhostInAMachine/gists{/gist_id}","starred_url":"https://api.github.com/users/GhostInAMachine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GhostInAMachine/subscriptions","organizations_url":"https://api.github.com/users/GhostInAMachine/orgs","repos_url":"https://api.github.com/users/GhostInAMachine/repos","events_url":"https://api.github.com/users/GhostInAMachine/events{/privacy}","received_events_url":"https://api.github.com/users/GhostInAMachine/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/GhostInAMachine/hazelcast-nodejs-client","description":"NodeJS Client for Hazelcast, using Hazelcast Open Client Protocol 1.0 for Hazelcast 3.6 and higher","fork":true,"url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client","forks_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/forks","keys_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/keys{/key_id}","collaborators_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/teams","hooks_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/hooks","issue_events_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/issues/events{/number}","events_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/events","assignees_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/assignees{/user}","branches_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/branches{/branch}","tags_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/tags","blobs_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/git/refs{/sha}","trees_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/git/trees{/sha}","statuses_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/statuses/{sha}","languages_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/languages","stargazers_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/stargazers","contributors_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/contributors","subscribers_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/subscribers","subscription_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/subscription","commits_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/commits{/sha}","git_commits_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/git/commits{/sha}","comments_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/comments{/number}","issue_comment_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/issues/comments{/number}","contents_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/contents/{+path}","compare_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/compare/{base}...{head}","merges_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/merges","archive_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/downloads","issues_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/issues{/number}","pulls_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/pulls{/number}","milestones_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/milestones{/number}","notifications_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/labels{/name}","releases_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/releases{/id}","deployments_url":"https://api.github.com/repos/GhostInAMachine/hazelcast-nodejs-client/deployments","created_at":"2015-12-14T17:15:57Z","updated_at":"2016-03-16T08:45:04Z","pushed_at":"2016-06-03T11:21:27Z","git_url":"git://github.com/GhostInAMachine/hazelcast-nodejs-client.git","ssh_url":"git@github.com:GhostInAMachine/hazelcast-nodejs-client.git","clone_url":"https://github.com/GhostInAMachine/hazelcast-nodejs-client.git","svn_url":"https://github.com/GhostInAMachine/hazelcast-nodejs-client","homepage":null,"size":435,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"hazelcast:master","ref":"master","sha":"1edcb6928c99cbd28ed6292c31410afe812920b8","user":{"login":"hazelcast","id":1453152,"avatar_url":"https://avatars.githubusercontent.com/u/1453152?v=3","gravatar_id":"","url":"https://api.github.com/users/hazelcast","html_url":"https://github.com/hazelcast","followers_url":"https://api.github.com/users/hazelcast/followers","following_url":"https://api.github.com/users/hazelcast/following{/other_user}","gists_url":"https://api.github.com/users/hazelcast/gists{/gist_id}","starred_url":"https://api.github.com/users/hazelcast/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hazelcast/subscriptions","organizations_url":"https://api.github.com/users/hazelcast/orgs","repos_url":"https://api.github.com/users/hazelcast/repos","events_url":"https://api.github.com/users/hazelcast/events{/privacy}","received_events_url":"https://api.github.com/users/hazelcast/received_events","type":"Organization","site_admin":false},"repo":{"id":45202495,"name":"hazelcast-nodejs-client","full_name":"hazelcast/hazelcast-nodejs-client","owner":{"login":"hazelcast","id":1453152,"avatar_url":"https://avatars.githubusercontent.com/u/1453152?v=3","gravatar_id":"","url":"https://api.github.com/users/hazelcast","html_url":"https://github.com/hazelcast","followers_url":"https://api.github.com/users/hazelcast/followers","following_url":"https://api.github.com/users/hazelcast/following{/other_user}","gists_url":"https://api.github.com/users/hazelcast/gists{/gist_id}","starred_url":"https://api.github.com/users/hazelcast/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hazelcast/subscriptions","organizations_url":"https://api.github.com/users/hazelcast/orgs","repos_url":"https://api.github.com/users/hazelcast/repos","events_url":"https://api.github.com/users/hazelcast/events{/privacy}","received_events_url":"https://api.github.com/users/hazelcast/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/hazelcast/hazelcast-nodejs-client","description":"NodeJS Client for Hazelcast, using Hazelcast Open Client Protocol 1.0 for Hazelcast 3.6 and higher","fork":false,"url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client","forks_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/forks","keys_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/keys{/key_id}","collaborators_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/teams","hooks_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/hooks","issue_events_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/issues/events{/number}","events_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/events","assignees_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/assignees{/user}","branches_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/branches{/branch}","tags_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/tags","blobs_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/git/refs{/sha}","trees_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/git/trees{/sha}","statuses_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/statuses/{sha}","languages_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/languages","stargazers_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/stargazers","contributors_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/contributors","subscribers_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/subscribers","subscription_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/subscription","commits_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/commits{/sha}","git_commits_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/git/commits{/sha}","comments_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/comments{/number}","issue_comment_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/issues/comments{/number}","contents_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/contents/{+path}","compare_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/compare/{base}...{head}","merges_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/merges","archive_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/downloads","issues_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/issues{/number}","pulls_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/pulls{/number}","milestones_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/milestones{/number}","notifications_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/labels{/name}","releases_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/releases{/id}","deployments_url":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/deployments","created_at":"2015-10-29T18:24:48Z","updated_at":"2016-05-25T08:53:49Z","pushed_at":"2016-06-03T11:21:51Z","git_url":"git://github.com/hazelcast/hazelcast-nodejs-client.git","ssh_url":"git@github.com:hazelcast/hazelcast-nodejs-client.git","clone_url":"https://github.com/hazelcast/hazelcast-nodejs-client.git","svn_url":"https://github.com/hazelcast/hazelcast-nodejs-client","homepage":"http://hazelcast.github.io/hazelcast-nodejs-client/","size":750,"stargazers_count":6,"watchers_count":6,"language":"TypeScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":6,"mirror_url":null,"open_issues_count":8,"forks":6,"open_issues":8,"watchers":6,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/pulls/108"},"html":{"href":"https://github.com/hazelcast/hazelcast-nodejs-client/pull/108"},"issue":{"href":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/issues/108"},"comments":{"href":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/issues/108/comments"},"review_comments":{"href":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/pulls/108/comments"},"review_comment":{"href":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/pulls/108/commits"},"statuses":{"href":"https://api.github.com/repos/hazelcast/hazelcast-nodejs-client/statuses/be6f6a26ca8cb6bf3050146e9d3fc8d0c2885e5e"}}}}
{"actor":{"display_login":"mustafaiman"}}