{"action":"created","comment":{"url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/pulls/comments/60182441","id":60182441,"diff_hunk":"@@ -0,0 +1,121 @@\n+/**\n+ * This Source Code Form is subject to the terms of the Mozilla Public License,\n+ * v. 2.0. If a copy of the MPL was not distributed with this file, You can\n+ * obtain one at http://mozilla.org/MPL/2.0/. OpenMRS is also distributed under\n+ * the terms of the Healthcare Disclaimer located at http://openmrs.org/license.\n+ *\n+ * Copyright (C) OpenMRS Inc. OpenMRS is a registered trademark and the OpenMRS\n+ * graphic logo is a trademark of OpenMRS Inc.\n+ */\n+package org.openmrs.module.radiology.validator;\n+\n+import java.util.List;\n+\n+import org.junit.Assert;\n+import org.junit.Test;\n+import org.openmrs.Provider;\n+import org.openmrs.module.radiology.RadiologyOrder;\n+import org.openmrs.Order;\n+import org.openmrs.test.Verifies;\n+import org.springframework.validation.BindException;\n+import org.springframework.validation.Errors;\n+import org.springframework.validation.ObjectError;\n+\n+/**\n+ * Tests methods on the {@link RadiologyDiscontinuedOrderValidator} class.\n+ */\n+public class RadiologyDiscontinuedOrderValidatorComponentTest {\n+\t\n+\t/**\n+\t * @see {@link RadiologyDiscontinuedOrderValidator#supports(Class c)}\n+\t */\n+\t@Test\n+\t@Verifies(value = \"should return true for Order objects and subclasses\", method = \"supports(Class c)\")\n+\tpublic void supports_shouldReturnTrueForOrderObjectsAndSubclasses() throws Exception {\n+\t\tRadiologyDiscontinuedOrderValidator radiologyDiscontinuedOrderValidator = new RadiologyDiscontinuedOrderValidator();","path":"api/src/test/java/org/openmrs/module/radiology/validator/RadiologyDiscontinuedOrderValidatorComponentTest.java","position":35,"original_position":35,"commit_id":"e00dd89772f8edef29d518cff8bba3e8bbb81b5a","original_commit_id":"e00dd89772f8edef29d518cff8bba3e8bbb81b5a","user":{"login":"teleivo","id":4661144,"avatar_url":"https://avatars.githubusercontent.com/u/4661144?v=3","gravatar_id":"","url":"https://api.github.com/users/teleivo","html_url":"https://github.com/teleivo","followers_url":"https://api.github.com/users/teleivo/followers","following_url":"https://api.github.com/users/teleivo/following{/other_user}","gists_url":"https://api.github.com/users/teleivo/gists{/gist_id}","starred_url":"https://api.github.com/users/teleivo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/teleivo/subscriptions","organizations_url":"https://api.github.com/users/teleivo/orgs","repos_url":"https://api.github.com/users/teleivo/repos","events_url":"https://api.github.com/users/teleivo/events{/privacy}","received_events_url":"https://api.github.com/users/teleivo/received_events","type":"User","site_admin":false},"body":"add newline in between method title and body. you did it for most methods here. be consistent","created_at":"2016-04-19T07:14:09Z","updated_at":"2016-04-19T07:14:09Z","html_url":"https://github.com/openmrs/openmrs-module-radiology/pull/239#discussion_r60182441","pull_request_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/pulls/239","_links":{"self":{"href":"https://api.github.com/repos/openmrs/openmrs-module-radiology/pulls/comments/60182441"},"html":{"href":"https://github.com/openmrs/openmrs-module-radiology/pull/239#discussion_r60182441"},"pull_request":{"href":"https://api.github.com/repos/openmrs/openmrs-module-radiology/pulls/239"}}},"pull_request":{"url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/pulls/239","id":66929724,"html_url":"https://github.com/openmrs/openmrs-module-radiology/pull/239","diff_url":"https://github.com/openmrs/openmrs-module-radiology/pull/239.diff","patch_url":"https://github.com/openmrs/openmrs-module-radiology/pull/239.patch","issue_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/issues/239","number":239,"state":"open","locked":false,"title":"RAD-217 Add tests for RadiologyDiscontinuedOrderValidator","user":{"login":"joehiggs","id":5335593,"avatar_url":"https://avatars.githubusercontent.com/u/5335593?v=3","gravatar_id":"","url":"https://api.github.com/users/joehiggs","html_url":"https://github.com/joehiggs","followers_url":"https://api.github.com/users/joehiggs/followers","following_url":"https://api.github.com/users/joehiggs/following{/other_user}","gists_url":"https://api.github.com/users/joehiggs/gists{/gist_id}","starred_url":"https://api.github.com/users/joehiggs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joehiggs/subscriptions","organizations_url":"https://api.github.com/users/joehiggs/orgs","repos_url":"https://api.github.com/users/joehiggs/repos","events_url":"https://api.github.com/users/joehiggs/events{/privacy}","received_events_url":"https://api.github.com/users/joehiggs/received_events","type":"User","site_admin":false},"body":"Make sure the supports(Class c) returns\r\n* true for objects assignable from the Order class\r\n* false for other types\r\n\r\nMake sure the validate(Object obj, Errors errors)\r\n* fails when\r\n** radiology order is null\r\n** orderer is null\r\n** orderReasonNonCoded is null\r\n* passes when\r\n** all fields are correct\r\n\r\nSee https://issues.openmrs.org/browse/RAD-217","created_at":"2016-04-18T22:02:46Z","updated_at":"2016-04-19T07:14:09Z","closed_at":null,"merged_at":null,"merge_commit_sha":"709830d1bd4830d8bbcdba3b64f7d2a9d637a8fb","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/pulls/239/commits","review_comments_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/pulls/239/comments","review_comment_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/pulls/comments{/number}","comments_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/issues/239/comments","statuses_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/statuses/e00dd89772f8edef29d518cff8bba3e8bbb81b5a","head":{"label":"joehiggs:RAD-217","ref":"RAD-217","sha":"e00dd89772f8edef29d518cff8bba3e8bbb81b5a","user":{"login":"joehiggs","id":5335593,"avatar_url":"https://avatars.githubusercontent.com/u/5335593?v=3","gravatar_id":"","url":"https://api.github.com/users/joehiggs","html_url":"https://github.com/joehiggs","followers_url":"https://api.github.com/users/joehiggs/followers","following_url":"https://api.github.com/users/joehiggs/following{/other_user}","gists_url":"https://api.github.com/users/joehiggs/gists{/gist_id}","starred_url":"https://api.github.com/users/joehiggs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joehiggs/subscriptions","organizations_url":"https://api.github.com/users/joehiggs/orgs","repos_url":"https://api.github.com/users/joehiggs/repos","events_url":"https://api.github.com/users/joehiggs/events{/privacy}","received_events_url":"https://api.github.com/users/joehiggs/received_events","type":"User","site_admin":false},"repo":{"id":55113308,"name":"openmrs-module-radiology","full_name":"joehiggs/openmrs-module-radiology","owner":{"login":"joehiggs","id":5335593,"avatar_url":"https://avatars.githubusercontent.com/u/5335593?v=3","gravatar_id":"","url":"https://api.github.com/users/joehiggs","html_url":"https://github.com/joehiggs","followers_url":"https://api.github.com/users/joehiggs/followers","following_url":"https://api.github.com/users/joehiggs/following{/other_user}","gists_url":"https://api.github.com/users/joehiggs/gists{/gist_id}","starred_url":"https://api.github.com/users/joehiggs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joehiggs/subscriptions","organizations_url":"https://api.github.com/users/joehiggs/orgs","repos_url":"https://api.github.com/users/joehiggs/repos","events_url":"https://api.github.com/users/joehiggs/events{/privacy}","received_events_url":"https://api.github.com/users/joehiggs/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/joehiggs/openmrs-module-radiology","description":"OpenMRS Radiology Module with dcm4chee","fork":true,"url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology","forks_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/forks","keys_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/keys{/key_id}","collaborators_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/teams","hooks_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/hooks","issue_events_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/issues/events{/number}","events_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/events","assignees_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/assignees{/user}","branches_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/branches{/branch}","tags_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/tags","blobs_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/git/refs{/sha}","trees_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/git/trees{/sha}","statuses_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/statuses/{sha}","languages_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/languages","stargazers_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/stargazers","contributors_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/contributors","subscribers_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/subscribers","subscription_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/subscription","commits_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/commits{/sha}","git_commits_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/git/commits{/sha}","comments_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/comments{/number}","issue_comment_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/issues/comments{/number}","contents_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/contents/{+path}","compare_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/compare/{base}...{head}","merges_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/merges","archive_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/downloads","issues_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/issues{/number}","pulls_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/pulls{/number}","milestones_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/milestones{/number}","notifications_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/labels{/name}","releases_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/releases{/id}","deployments_url":"https://api.github.com/repos/joehiggs/openmrs-module-radiology/deployments","created_at":"2016-03-31T02:21:14Z","updated_at":"2016-03-31T02:21:15Z","pushed_at":"2016-04-19T03:54:40Z","git_url":"git://github.com/joehiggs/openmrs-module-radiology.git","ssh_url":"git@github.com:joehiggs/openmrs-module-radiology.git","clone_url":"https://github.com/joehiggs/openmrs-module-radiology.git","svn_url":"https://github.com/joehiggs/openmrs-module-radiology","homepage":null,"size":71464,"stargazers_count":0,"watchers_count":0,"language":"Java","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":"openmrs:master","ref":"master","sha":"f60810ae998277524776859e81e0423d86cd4d7d","user":{"login":"openmrs","id":860776,"avatar_url":"https://avatars.githubusercontent.com/u/860776?v=3","gravatar_id":"","url":"https://api.github.com/users/openmrs","html_url":"https://github.com/openmrs","followers_url":"https://api.github.com/users/openmrs/followers","following_url":"https://api.github.com/users/openmrs/following{/other_user}","gists_url":"https://api.github.com/users/openmrs/gists{/gist_id}","starred_url":"https://api.github.com/users/openmrs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openmrs/subscriptions","organizations_url":"https://api.github.com/users/openmrs/orgs","repos_url":"https://api.github.com/users/openmrs/repos","events_url":"https://api.github.com/users/openmrs/events{/privacy}","received_events_url":"https://api.github.com/users/openmrs/received_events","type":"Organization","site_admin":false},"repo":{"id":13028147,"name":"openmrs-module-radiology","full_name":"openmrs/openmrs-module-radiology","owner":{"login":"openmrs","id":860776,"avatar_url":"https://avatars.githubusercontent.com/u/860776?v=3","gravatar_id":"","url":"https://api.github.com/users/openmrs","html_url":"https://github.com/openmrs","followers_url":"https://api.github.com/users/openmrs/followers","following_url":"https://api.github.com/users/openmrs/following{/other_user}","gists_url":"https://api.github.com/users/openmrs/gists{/gist_id}","starred_url":"https://api.github.com/users/openmrs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openmrs/subscriptions","organizations_url":"https://api.github.com/users/openmrs/orgs","repos_url":"https://api.github.com/users/openmrs/repos","events_url":"https://api.github.com/users/openmrs/events{/privacy}","received_events_url":"https://api.github.com/users/openmrs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/openmrs/openmrs-module-radiology","description":"OpenMRS Radiology Module with dcm4chee","fork":false,"url":"https://api.github.com/repos/openmrs/openmrs-module-radiology","forks_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/forks","keys_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/keys{/key_id}","collaborators_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/teams","hooks_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/hooks","issue_events_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/issues/events{/number}","events_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/events","assignees_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/assignees{/user}","branches_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/branches{/branch}","tags_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/tags","blobs_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/git/refs{/sha}","trees_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/git/trees{/sha}","statuses_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/statuses/{sha}","languages_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/languages","stargazers_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/stargazers","contributors_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/contributors","subscribers_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/subscribers","subscription_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/subscription","commits_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/commits{/sha}","git_commits_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/git/commits{/sha}","comments_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/comments{/number}","issue_comment_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/issues/comments{/number}","contents_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/contents/{+path}","compare_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/compare/{base}...{head}","merges_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/merges","archive_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/downloads","issues_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/issues{/number}","pulls_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/pulls{/number}","milestones_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/milestones{/number}","notifications_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/labels{/name}","releases_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/releases{/id}","deployments_url":"https://api.github.com/repos/openmrs/openmrs-module-radiology/deployments","created_at":"2013-09-23T06:03:47Z","updated_at":"2016-04-19T02:48:05Z","pushed_at":"2016-04-19T03:57:15Z","git_url":"git://github.com/openmrs/openmrs-module-radiology.git","ssh_url":"git@github.com:openmrs/openmrs-module-radiology.git","clone_url":"https://github.com/openmrs/openmrs-module-radiology.git","svn_url":"https://github.com/openmrs/openmrs-module-radiology","homepage":null,"size":71584,"stargazers_count":7,"watchers_count":7,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":31,"mirror_url":null,"open_issues_count":3,"forks":31,"open_issues":3,"watchers":7,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/openmrs/openmrs-module-radiology/pulls/239"},"html":{"href":"https://github.com/openmrs/openmrs-module-radiology/pull/239"},"issue":{"href":"https://api.github.com/repos/openmrs/openmrs-module-radiology/issues/239"},"comments":{"href":"https://api.github.com/repos/openmrs/openmrs-module-radiology/issues/239/comments"},"review_comments":{"href":"https://api.github.com/repos/openmrs/openmrs-module-radiology/pulls/239/comments"},"review_comment":{"href":"https://api.github.com/repos/openmrs/openmrs-module-radiology/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/openmrs/openmrs-module-radiology/pulls/239/commits"},"statuses":{"href":"https://api.github.com/repos/openmrs/openmrs-module-radiology/statuses/e00dd89772f8edef29d518cff8bba3e8bbb81b5a"}}}}