{"action":"created","comment":{"url":"https://api.github.com/repos/RackHD/on-http/pulls/comments/53386401","id":53386401,"diff_hunk":"@@ -0,0 +1,233 @@\n+// Copyright 2016, EMC, Inc.\n+/* jshint node:true */\n+\n+\"use strict\";\n+\n+describe(\"Http.Services.Api.Obms\", function () {\n+    var obmService;\n+    var Promise;\n+    var chai = require('chai');\n+    chai.use(require('chai-string'));\n+    before(\"Http.Services.Api.Obms before\", function() {\n+        helper.setupInjector([\n+            helper.require(\"/lib/services/obm-api-service.js\")\n+        ]);\n+\n+        Promise = helper.injector.get('Promise');\n+        obmService = helper.injector.get(\"Http.Services.Api.Obms\");\n+\n+    });\n+\n+    var mockObms = [\n+    {\n+        \"config\": {\n+            \"host\": {\n+                \"default\": \"localhost\",\n+                \"type\": \"string\"\n+            },\n+            \"password\": {\n+                \"default\": \"admin\",\n+                \"type\": \"string\"\n+            }\n+        },\n+        \"service\": \"amt-obm-service\"\n+    },\n+    {\n+        \"config\": {\n+            \"community\": {\n+                \"default\": \"admin\",\n+                \"type\": \"string\"\n+            },\n+            \"host\": {\n+                \"default\": \"localhost\",\n+                \"type\": \"string\"\n+            },\n+            \"port\": {\n+                \"default\": 1,\n+                \"type\": \"integer\"\n+            }\n+        },\n+        \"service\": \"apc-obm-service\"\n+    },\n+    {\n+        \"config\": {\n+            \"host\": {\n+                \"default\": \"localhost\",\n+                \"type\": \"string\"\n+            },\n+            \"password\": {\n+                \"default\": \"admin\",\n+                \"type\": \"string\"\n+            },\n+            \"user\": {\n+                \"default\": \"admin\",\n+                \"type\": \"string\"\n+            }\n+        },\n+        \"service\": \"ipmi-obm-service\"\n+    },\n+    {\n+        \"config\": {},\n+        \"service\": \"noop-obm-service\"\n+    },\n+    {\n+        \"config\": {\n+            \"host\": {\n+                \"default\": \"localhost\",\n+                \"type\": \"string\"\n+            },\n+            \"password\": {\n+                \"default\": \"admin\",\n+                \"type\": \"string\"\n+            },\n+            \"port\": {\n+                \"default\": 1,\n+                \"type\": \"integer\"\n+            },\n+            \"user\": {\n+                \"default\": \"admin\",\n+                \"type\": \"string\"\n+            }\n+        },\n+        \"service\": \"raritan-obm-service\"\n+    },\n+    {\n+        \"config\": {\n+            \"community\": {\n+                \"default\": \"admin\",\n+                \"type\": \"string\"\n+            },\n+            \"host\": {\n+                \"default\": \"localhost\",\n+                \"type\": \"string\"\n+            },\n+            \"port\": {\n+                \"default\": 1,\n+                \"type\": \"integer\"\n+            }\n+        },\n+        \"service\": \"servertech-obm-service\"\n+    },\n+    {\n+        \"config\": {\n+            \"community\": {\n+                \"default\": \"admin\",\n+                \"type\": \"string\"\n+            },\n+            \"cyclePassword\": {\n+                \"default\": \"onrack\",\n+                \"type\": \"string\"\n+            },\n+            \"host\": {\n+                \"default\": \"localhost\",\n+                \"type\": \"string\"\n+            },\n+            \"pduOutlets\": [\n+                {\n+                    \"community\": {\n+                        \"default\": \"admin\",\n+                        \"type\": \"string\"\n+                    },\n+                    \"cyclePassword\": {\n+                        \"default\": \"A01\",\n+                        \"type\": \"string\"\n+                    },\n+                    \"host\": {\n+                        \"default\": \"localhost\",\n+                        \"type\": \"string\"\n+                    },\n+                    \"outletNumber\": {\n+                        \"default\": 1,\n+                        \"type\": \"integer\"\n+                    },\n+                    \"pduNumber\": {\n+                        \"default\": 1,\n+                        \"type\": \"integer\"\n+                    }\n+                },\n+                {\n+                    \"community\": {\n+                        \"default\": \"admin\",\n+                        \"type\": \"string\"\n+                    },\n+                    \"cyclePassword\": {\n+                        \"default\": \"A01\",\n+                        \"type\": \"string\"\n+                    },\n+                    \"host\": {\n+                        \"default\": \"localhost\",\n+                        \"type\": \"string\"\n+                    },\n+                    \"outletNumber\": {\n+                        \"default\": 1,\n+                        \"type\": \"integer\"\n+                    },\n+                    \"pduNumber\": {\n+                        \"default\": 2,\n+                        \"type\": \"integer\"\n+                    }\n+                }\n+            ]\n+        },\n+        \"service\": \"panduit-obm-service\"\n+    },\n+    {\n+        \"config\": {\n+            \"alias\": {\n+                \"default\": \"client\",\n+                \"type\": \"string\"\n+            },\n+            \"user\": {\n+                \"default\": \"root\",\n+                \"type\": \"string\"\n+            }\n+        },\n+        \"service\": \"vbox-obm-service\"\n+    },\n+    {\n+        \"config\": {\n+            \"vmxpath\": {\n+                \"default\": \"/tmp/vm.vmx\",\n+                \"type\": \"string\"\n+            }\n+        },\n+        \"service\": \"vmrun-obm-service\"\n+    }\n+    ]\n+    describe(\"getObmLib\", function() {\n+        it('should expose the appropriate methods', function() {\n+            obmService.should.have.property('getObmLib')\n+                .that.is.a('function').with.length(0);\n+        });\n+\n+        it('Run getObm', function() {\n+            var temp = obmService.getObmLib();\n+            expect(temp.toString()).to.equalIgnoreCase(mockObms.toString());\n+        });\n+    });\n+    \n+    describe(\"getObmLibById\", function() {\n+        it('should expose the appropriate methods', function() {\n+            obmService.should.have.property('getObmLibById')\n+            .that.is.a('function').with.length(1);\n+        });\n+        it('Run getObmLibById', function() {\n+            var mockObm = {\n+                          \"config\": {\n+                              \"vmxpath\": {\n+                              \"default\": \"/tmp/vm.vmx\",\n+                              \"type\": \"string\"\n+                              }\n+                          },\n+                          \"service\": \"vmrun-obm-service\"\n+                          }","path":"spec/lib/services/obm-api-service-spec.js","position":223,"original_position":223,"commit_id":"a04bff75a0d6a69133e72212ebde983bd10b5993","original_commit_id":"a04bff75a0d6a69133e72212ebde983bd10b5993","user":{"login":"houndci-bot","id":6697940,"avatar_url":"https://avatars.githubusercontent.com/u/6697940?v=3","gravatar_id":"","url":"https://api.github.com/users/houndci-bot","html_url":"https://github.com/houndci-bot","followers_url":"https://api.github.com/users/houndci-bot/followers","following_url":"https://api.github.com/users/houndci-bot/following{/other_user}","gists_url":"https://api.github.com/users/houndci-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci-bot/subscriptions","organizations_url":"https://api.github.com/users/houndci-bot/orgs","repos_url":"https://api.github.com/users/houndci-bot/repos","events_url":"https://api.github.com/users/houndci-bot/events{/privacy}","received_events_url":"https://api.github.com/users/houndci-bot/received_events","type":"User","site_admin":false},"body":"Missing semicolon.","created_at":"2016-02-18T21:35:47Z","updated_at":"2016-02-18T21:35:47Z","html_url":"https://github.com/RackHD/on-http/pull/137#discussion_r53386401","pull_request_url":"https://api.github.com/repos/RackHD/on-http/pulls/137","_links":{"self":{"href":"https://api.github.com/repos/RackHD/on-http/pulls/comments/53386401"},"html":{"href":"https://github.com/RackHD/on-http/pull/137#discussion_r53386401"},"pull_request":{"href":"https://api.github.com/repos/RackHD/on-http/pulls/137"}}},"pull_request":{"url":"https://api.github.com/repos/RackHD/on-http/pulls/137","id":59867010,"html_url":"https://github.com/RackHD/on-http/pull/137","diff_url":"https://github.com/RackHD/on-http/pull/137.diff","patch_url":"https://github.com/RackHD/on-http/pull/137.patch","issue_url":"https://api.github.com/repos/RackHD/on-http/issues/137","number":137,"state":"open","locked":false,"title":"Feature/swagger obm route","user":{"login":"srinia6","id":14314211,"avatar_url":"https://avatars.githubusercontent.com/u/14314211?v=3","gravatar_id":"","url":"https://api.github.com/users/srinia6","html_url":"https://github.com/srinia6","followers_url":"https://api.github.com/users/srinia6/followers","following_url":"https://api.github.com/users/srinia6/following{/other_user}","gists_url":"https://api.github.com/users/srinia6/gists{/gist_id}","starred_url":"https://api.github.com/users/srinia6/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/srinia6/subscriptions","organizations_url":"https://api.github.com/users/srinia6/orgs","repos_url":"https://api.github.com/users/srinia6/repos","events_url":"https://api.github.com/users/srinia6/events{/privacy}","received_events_url":"https://api.github.com/users/srinia6/received_events","type":"User","site_admin":false},"body":"Controller for OBM route.","created_at":"2016-02-18T21:34:53Z","updated_at":"2016-02-18T21:35:47Z","closed_at":null,"merged_at":null,"merge_commit_sha":"dc20add1771a04f2df84cd445ae09dee83d143c6","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/RackHD/on-http/pulls/137/commits","review_comments_url":"https://api.github.com/repos/RackHD/on-http/pulls/137/comments","review_comment_url":"https://api.github.com/repos/RackHD/on-http/pulls/comments{/number}","comments_url":"https://api.github.com/repos/RackHD/on-http/issues/137/comments","statuses_url":"https://api.github.com/repos/RackHD/on-http/statuses/a04bff75a0d6a69133e72212ebde983bd10b5993","head":{"label":"srinia6:feature/swagger-obm-route","ref":"feature/swagger-obm-route","sha":"a04bff75a0d6a69133e72212ebde983bd10b5993","user":{"login":"srinia6","id":14314211,"avatar_url":"https://avatars.githubusercontent.com/u/14314211?v=3","gravatar_id":"","url":"https://api.github.com/users/srinia6","html_url":"https://github.com/srinia6","followers_url":"https://api.github.com/users/srinia6/followers","following_url":"https://api.github.com/users/srinia6/following{/other_user}","gists_url":"https://api.github.com/users/srinia6/gists{/gist_id}","starred_url":"https://api.github.com/users/srinia6/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/srinia6/subscriptions","organizations_url":"https://api.github.com/users/srinia6/orgs","repos_url":"https://api.github.com/users/srinia6/repos","events_url":"https://api.github.com/users/srinia6/events{/privacy}","received_events_url":"https://api.github.com/users/srinia6/received_events","type":"User","site_admin":false},"repo":{"id":49977583,"name":"on-http","full_name":"srinia6/on-http","owner":{"login":"srinia6","id":14314211,"avatar_url":"https://avatars.githubusercontent.com/u/14314211?v=3","gravatar_id":"","url":"https://api.github.com/users/srinia6","html_url":"https://github.com/srinia6","followers_url":"https://api.github.com/users/srinia6/followers","following_url":"https://api.github.com/users/srinia6/following{/other_user}","gists_url":"https://api.github.com/users/srinia6/gists{/gist_id}","starred_url":"https://api.github.com/users/srinia6/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/srinia6/subscriptions","organizations_url":"https://api.github.com/users/srinia6/orgs","repos_url":"https://api.github.com/users/srinia6/repos","events_url":"https://api.github.com/users/srinia6/events{/privacy}","received_events_url":"https://api.github.com/users/srinia6/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/srinia6/on-http","description":"","fork":true,"url":"https://api.github.com/repos/srinia6/on-http","forks_url":"https://api.github.com/repos/srinia6/on-http/forks","keys_url":"https://api.github.com/repos/srinia6/on-http/keys{/key_id}","collaborators_url":"https://api.github.com/repos/srinia6/on-http/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/srinia6/on-http/teams","hooks_url":"https://api.github.com/repos/srinia6/on-http/hooks","issue_events_url":"https://api.github.com/repos/srinia6/on-http/issues/events{/number}","events_url":"https://api.github.com/repos/srinia6/on-http/events","assignees_url":"https://api.github.com/repos/srinia6/on-http/assignees{/user}","branches_url":"https://api.github.com/repos/srinia6/on-http/branches{/branch}","tags_url":"https://api.github.com/repos/srinia6/on-http/tags","blobs_url":"https://api.github.com/repos/srinia6/on-http/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/srinia6/on-http/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/srinia6/on-http/git/refs{/sha}","trees_url":"https://api.github.com/repos/srinia6/on-http/git/trees{/sha}","statuses_url":"https://api.github.com/repos/srinia6/on-http/statuses/{sha}","languages_url":"https://api.github.com/repos/srinia6/on-http/languages","stargazers_url":"https://api.github.com/repos/srinia6/on-http/stargazers","contributors_url":"https://api.github.com/repos/srinia6/on-http/contributors","subscribers_url":"https://api.github.com/repos/srinia6/on-http/subscribers","subscription_url":"https://api.github.com/repos/srinia6/on-http/subscription","commits_url":"https://api.github.com/repos/srinia6/on-http/commits{/sha}","git_commits_url":"https://api.github.com/repos/srinia6/on-http/git/commits{/sha}","comments_url":"https://api.github.com/repos/srinia6/on-http/comments{/number}","issue_comment_url":"https://api.github.com/repos/srinia6/on-http/issues/comments{/number}","contents_url":"https://api.github.com/repos/srinia6/on-http/contents/{+path}","compare_url":"https://api.github.com/repos/srinia6/on-http/compare/{base}...{head}","merges_url":"https://api.github.com/repos/srinia6/on-http/merges","archive_url":"https://api.github.com/repos/srinia6/on-http/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/srinia6/on-http/downloads","issues_url":"https://api.github.com/repos/srinia6/on-http/issues{/number}","pulls_url":"https://api.github.com/repos/srinia6/on-http/pulls{/number}","milestones_url":"https://api.github.com/repos/srinia6/on-http/milestones{/number}","notifications_url":"https://api.github.com/repos/srinia6/on-http/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/srinia6/on-http/labels{/name}","releases_url":"https://api.github.com/repos/srinia6/on-http/releases{/id}","deployments_url":"https://api.github.com/repos/srinia6/on-http/deployments","created_at":"2016-01-19T19:32:25Z","updated_at":"2016-01-19T19:32:26Z","pushed_at":"2016-02-18T20:03:09Z","git_url":"git://github.com/srinia6/on-http.git","ssh_url":"git@github.com:srinia6/on-http.git","clone_url":"https://github.com/srinia6/on-http.git","svn_url":"https://github.com/srinia6/on-http","homepage":null,"size":1923,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"RackHD:master","ref":"master","sha":"6181407c18334596bea1d89d3b6a90b52b691e26","user":{"login":"RackHD","id":13982662,"avatar_url":"https://avatars.githubusercontent.com/u/13982662?v=3","gravatar_id":"","url":"https://api.github.com/users/RackHD","html_url":"https://github.com/RackHD","followers_url":"https://api.github.com/users/RackHD/followers","following_url":"https://api.github.com/users/RackHD/following{/other_user}","gists_url":"https://api.github.com/users/RackHD/gists{/gist_id}","starred_url":"https://api.github.com/users/RackHD/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RackHD/subscriptions","organizations_url":"https://api.github.com/users/RackHD/orgs","repos_url":"https://api.github.com/users/RackHD/repos","events_url":"https://api.github.com/users/RackHD/events{/privacy}","received_events_url":"https://api.github.com/users/RackHD/received_events","type":"Organization","site_admin":false},"repo":{"id":41690081,"name":"on-http","full_name":"RackHD/on-http","owner":{"login":"RackHD","id":13982662,"avatar_url":"https://avatars.githubusercontent.com/u/13982662?v=3","gravatar_id":"","url":"https://api.github.com/users/RackHD","html_url":"https://github.com/RackHD","followers_url":"https://api.github.com/users/RackHD/followers","following_url":"https://api.github.com/users/RackHD/following{/other_user}","gists_url":"https://api.github.com/users/RackHD/gists{/gist_id}","starred_url":"https://api.github.com/users/RackHD/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RackHD/subscriptions","organizations_url":"https://api.github.com/users/RackHD/orgs","repos_url":"https://api.github.com/users/RackHD/repos","events_url":"https://api.github.com/users/RackHD/events{/privacy}","received_events_url":"https://api.github.com/users/RackHD/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/RackHD/on-http","description":"","fork":false,"url":"https://api.github.com/repos/RackHD/on-http","forks_url":"https://api.github.com/repos/RackHD/on-http/forks","keys_url":"https://api.github.com/repos/RackHD/on-http/keys{/key_id}","collaborators_url":"https://api.github.com/repos/RackHD/on-http/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/RackHD/on-http/teams","hooks_url":"https://api.github.com/repos/RackHD/on-http/hooks","issue_events_url":"https://api.github.com/repos/RackHD/on-http/issues/events{/number}","events_url":"https://api.github.com/repos/RackHD/on-http/events","assignees_url":"https://api.github.com/repos/RackHD/on-http/assignees{/user}","branches_url":"https://api.github.com/repos/RackHD/on-http/branches{/branch}","tags_url":"https://api.github.com/repos/RackHD/on-http/tags","blobs_url":"https://api.github.com/repos/RackHD/on-http/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/RackHD/on-http/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/RackHD/on-http/git/refs{/sha}","trees_url":"https://api.github.com/repos/RackHD/on-http/git/trees{/sha}","statuses_url":"https://api.github.com/repos/RackHD/on-http/statuses/{sha}","languages_url":"https://api.github.com/repos/RackHD/on-http/languages","stargazers_url":"https://api.github.com/repos/RackHD/on-http/stargazers","contributors_url":"https://api.github.com/repos/RackHD/on-http/contributors","subscribers_url":"https://api.github.com/repos/RackHD/on-http/subscribers","subscription_url":"https://api.github.com/repos/RackHD/on-http/subscription","commits_url":"https://api.github.com/repos/RackHD/on-http/commits{/sha}","git_commits_url":"https://api.github.com/repos/RackHD/on-http/git/commits{/sha}","comments_url":"https://api.github.com/repos/RackHD/on-http/comments{/number}","issue_comment_url":"https://api.github.com/repos/RackHD/on-http/issues/comments{/number}","contents_url":"https://api.github.com/repos/RackHD/on-http/contents/{+path}","compare_url":"https://api.github.com/repos/RackHD/on-http/compare/{base}...{head}","merges_url":"https://api.github.com/repos/RackHD/on-http/merges","archive_url":"https://api.github.com/repos/RackHD/on-http/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/RackHD/on-http/downloads","issues_url":"https://api.github.com/repos/RackHD/on-http/issues{/number}","pulls_url":"https://api.github.com/repos/RackHD/on-http/pulls{/number}","milestones_url":"https://api.github.com/repos/RackHD/on-http/milestones{/number}","notifications_url":"https://api.github.com/repos/RackHD/on-http/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/RackHD/on-http/labels{/name}","releases_url":"https://api.github.com/repos/RackHD/on-http/releases{/id}","deployments_url":"https://api.github.com/repos/RackHD/on-http/deployments","created_at":"2015-08-31T17:29:08Z","updated_at":"2016-01-31T09:01:04Z","pushed_at":"2016-02-18T21:34:53Z","git_url":"git://github.com/RackHD/on-http.git","ssh_url":"git@github.com:RackHD/on-http.git","clone_url":"https://github.com/RackHD/on-http.git","svn_url":"https://github.com/RackHD/on-http","homepage":null,"size":2231,"stargazers_count":8,"watchers_count":8,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":31,"mirror_url":null,"open_issues_count":6,"forks":31,"open_issues":6,"watchers":8,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/RackHD/on-http/pulls/137"},"html":{"href":"https://github.com/RackHD/on-http/pull/137"},"issue":{"href":"https://api.github.com/repos/RackHD/on-http/issues/137"},"comments":{"href":"https://api.github.com/repos/RackHD/on-http/issues/137/comments"},"review_comments":{"href":"https://api.github.com/repos/RackHD/on-http/pulls/137/comments"},"review_comment":{"href":"https://api.github.com/repos/RackHD/on-http/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/RackHD/on-http/pulls/137/commits"},"statuses":{"href":"https://api.github.com/repos/RackHD/on-http/statuses/a04bff75a0d6a69133e72212ebde983bd10b5993"}}}}