{"action":"created","comment":{"url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/pulls/comments/67982705","id":67982705,"diff_hunk":"@@ -225,4 +225,35 @@ public function testCanConstructDescriptionFromValidDataValue() {\n \t\t);\n \t}\n \n+\tpublic function testCanConstructDescriptionFromMonolingualTextValue() {\n+\n+\t\t$containerSemanticData = $this->getMockBuilder( '\\SMWContainerSemanticData' )\n+\t\t\t->disableOriginalConstructor()\n+\t\t\t->getMock();\n+\n+\t\t$containerSemanticData->expects( $this->atLeastOnce() )\n+\t\t\t->method( 'getPropertyValues' )\n+\t\t\t->will( $this->returnValue( array( $this->dataItemFactory->newDIBlob( 'Bar' ) ) ) );\n+\n+\t\t$dataValue = $this->getMockBuilder( '\\SMW\\DataValues\\MonolingualTextValue' )\n+\t\t\t->disableOriginalConstructor()\n+\t\t\t->setMethods( array( 'isValid', 'getProperty', 'getDataItem' ) )\n+\t\t\t->getMock();\n+\n+\t\t$dataValue->expects( $this->atLeastOnce() )\n+\t\t\t->method( 'isValid' )\n+\t\t\t->will( $this->returnValue( true ) );\n+\n+\t\t$dataValue->expects( $this->atLeastOnce() )\n+\t\t\t->method( 'getDataItem' )\n+\t\t\t->will( $this->returnValue( $this->dataItemFactory->newDIContainer( $containerSemanticData ) ) );\n+\n+\t\t$instance = new DescriptionFactory();\n+\n+\t\t$this->assertInstanceOf(\n+\t\t\t'SMW\\Query\\Language\\Conjunction',\n+\t\t\t$instance->newFromDataValue( $dataValue )\n+\t\t);\n+\t}","path":"tests/phpunit/Unit/Query/DescriptionFactoryTest.php","position":33,"original_position":33,"commit_id":"2e710024277c33c7a5d0cc8704b28585693f10c3","original_commit_id":"2e710024277c33c7a5d0cc8704b28585693f10c3","user":{"login":"mwjames","id":1245473,"avatar_url":"https://avatars.githubusercontent.com/u/1245473?v=3","gravatar_id":"","url":"https://api.github.com/users/mwjames","html_url":"https://github.com/mwjames","followers_url":"https://api.github.com/users/mwjames/followers","following_url":"https://api.github.com/users/mwjames/following{/other_user}","gists_url":"https://api.github.com/users/mwjames/gists{/gist_id}","starred_url":"https://api.github.com/users/mwjames/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mwjames/subscriptions","organizations_url":"https://api.github.com/users/mwjames/orgs","repos_url":"https://api.github.com/users/mwjames/repos","events_url":"https://api.github.com/users/mwjames/events{/privacy}","received_events_url":"https://api.github.com/users/mwjames/received_events","type":"User","site_admin":false},"body":"> This test has 9 string references to code and binds to implementation details.\r\n\r\nYes, that's purpose and if someone breaks the interface the test will fail and that is what I'm counting on. Writing a \"real\" test double is just not worth it, for this you have the mock object.","created_at":"2016-06-22T01:43:13Z","updated_at":"2016-06-22T01:43:13Z","html_url":"https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/1661#discussion_r67982705","pull_request_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/pulls/1661","_links":{"self":{"href":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/pulls/comments/67982705"},"html":{"href":"https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/1661#discussion_r67982705"},"pull_request":{"href":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/pulls/1661"}}},"pull_request":{"url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/pulls/1661","id":74192747,"html_url":"https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/1661","diff_url":"https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/1661.diff","patch_url":"https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/1661.patch","issue_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/issues/1661","number":1661,"state":"closed","locked":false,"title":"Fixed ref to MonolingualTextValue","user":{"login":"JeroenDeDauw","id":146040,"avatar_url":"https://avatars.githubusercontent.com/u/146040?v=3","gravatar_id":"","url":"https://api.github.com/users/JeroenDeDauw","html_url":"https://github.com/JeroenDeDauw","followers_url":"https://api.github.com/users/JeroenDeDauw/followers","following_url":"https://api.github.com/users/JeroenDeDauw/following{/other_user}","gists_url":"https://api.github.com/users/JeroenDeDauw/gists{/gist_id}","starred_url":"https://api.github.com/users/JeroenDeDauw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JeroenDeDauw/subscriptions","organizations_url":"https://api.github.com/users/JeroenDeDauw/orgs","repos_url":"https://api.github.com/users/JeroenDeDauw/repos","events_url":"https://api.github.com/users/JeroenDeDauw/events{/privacy}","received_events_url":"https://api.github.com/users/JeroenDeDauw/received_events","type":"User","site_admin":false},"body":"NOTE: this code is clearly not tested, as execution of the part\r\nthat refs MonolingualTextValue should result in an error before\r\nthis change.","created_at":"2016-06-17T06:03:14Z","updated_at":"2016-06-22T01:43:13Z","closed_at":"2016-06-18T15:10:36Z","merged_at":"2016-06-18T15:10:36Z","merge_commit_sha":"57be7de66da56922fa5690a82f2cc3fc20ce4c5a","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/pulls/1661/commits","review_comments_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/pulls/1661/comments","review_comment_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/pulls/comments{/number}","comments_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/issues/1661/comments","statuses_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/statuses/2e710024277c33c7a5d0cc8704b28585693f10c3","head":{"label":"SemanticMediaWiki:MonolingualTextValue","ref":"MonolingualTextValue","sha":"2e710024277c33c7a5d0cc8704b28585693f10c3","user":{"login":"SemanticMediaWiki","id":1623598,"avatar_url":"https://avatars.githubusercontent.com/u/1623598?v=3","gravatar_id":"","url":"https://api.github.com/users/SemanticMediaWiki","html_url":"https://github.com/SemanticMediaWiki","followers_url":"https://api.github.com/users/SemanticMediaWiki/followers","following_url":"https://api.github.com/users/SemanticMediaWiki/following{/other_user}","gists_url":"https://api.github.com/users/SemanticMediaWiki/gists{/gist_id}","starred_url":"https://api.github.com/users/SemanticMediaWiki/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SemanticMediaWiki/subscriptions","organizations_url":"https://api.github.com/users/SemanticMediaWiki/orgs","repos_url":"https://api.github.com/users/SemanticMediaWiki/repos","events_url":"https://api.github.com/users/SemanticMediaWiki/events{/privacy}","received_events_url":"https://api.github.com/users/SemanticMediaWiki/received_events","type":"Organization","site_admin":false},"repo":{"id":14058345,"name":"SemanticMediaWiki","full_name":"SemanticMediaWiki/SemanticMediaWiki","owner":{"login":"SemanticMediaWiki","id":1623598,"avatar_url":"https://avatars.githubusercontent.com/u/1623598?v=3","gravatar_id":"","url":"https://api.github.com/users/SemanticMediaWiki","html_url":"https://github.com/SemanticMediaWiki","followers_url":"https://api.github.com/users/SemanticMediaWiki/followers","following_url":"https://api.github.com/users/SemanticMediaWiki/following{/other_user}","gists_url":"https://api.github.com/users/SemanticMediaWiki/gists{/gist_id}","starred_url":"https://api.github.com/users/SemanticMediaWiki/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SemanticMediaWiki/subscriptions","organizations_url":"https://api.github.com/users/SemanticMediaWiki/orgs","repos_url":"https://api.github.com/users/SemanticMediaWiki/repos","events_url":"https://api.github.com/users/SemanticMediaWiki/events{/privacy}","received_events_url":"https://api.github.com/users/SemanticMediaWiki/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/SemanticMediaWiki/SemanticMediaWiki","description":"Semantic MediaWiki is a project for extending MediaWiki with \"semantic\" functions that enable machine-reading of wiki-content.","fork":false,"url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki","forks_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/forks","keys_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/keys{/key_id}","collaborators_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/teams","hooks_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/hooks","issue_events_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/issues/events{/number}","events_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/events","assignees_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/assignees{/user}","branches_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/branches{/branch}","tags_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/tags","blobs_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/git/refs{/sha}","trees_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/git/trees{/sha}","statuses_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/statuses/{sha}","languages_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/languages","stargazers_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/stargazers","contributors_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/contributors","subscribers_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/subscribers","subscription_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/subscription","commits_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/commits{/sha}","git_commits_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/git/commits{/sha}","comments_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/comments{/number}","issue_comment_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/issues/comments{/number}","contents_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/contents/{+path}","compare_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/compare/{base}...{head}","merges_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/merges","archive_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/downloads","issues_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/issues{/number}","pulls_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/pulls{/number}","milestones_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/milestones{/number}","notifications_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/labels{/name}","releases_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/releases{/id}","deployments_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/deployments","created_at":"2013-11-02T01:38:36Z","updated_at":"2016-06-12T18:45:19Z","pushed_at":"2016-06-22T00:19:42Z","git_url":"git://github.com/SemanticMediaWiki/SemanticMediaWiki.git","ssh_url":"git@github.com:SemanticMediaWiki/SemanticMediaWiki.git","clone_url":"https://github.com/SemanticMediaWiki/SemanticMediaWiki.git","svn_url":"https://github.com/SemanticMediaWiki/SemanticMediaWiki","homepage":"https://www.semantic-mediawiki.org/","size":25376,"stargazers_count":104,"watchers_count":104,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":71,"mirror_url":null,"open_issues_count":134,"forks":71,"open_issues":134,"watchers":104,"default_branch":"master"}},"base":{"label":"SemanticMediaWiki:master","ref":"master","sha":"eb3b3efb6173d9fde997832bdd8b765e3ed4f1e3","user":{"login":"SemanticMediaWiki","id":1623598,"avatar_url":"https://avatars.githubusercontent.com/u/1623598?v=3","gravatar_id":"","url":"https://api.github.com/users/SemanticMediaWiki","html_url":"https://github.com/SemanticMediaWiki","followers_url":"https://api.github.com/users/SemanticMediaWiki/followers","following_url":"https://api.github.com/users/SemanticMediaWiki/following{/other_user}","gists_url":"https://api.github.com/users/SemanticMediaWiki/gists{/gist_id}","starred_url":"https://api.github.com/users/SemanticMediaWiki/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SemanticMediaWiki/subscriptions","organizations_url":"https://api.github.com/users/SemanticMediaWiki/orgs","repos_url":"https://api.github.com/users/SemanticMediaWiki/repos","events_url":"https://api.github.com/users/SemanticMediaWiki/events{/privacy}","received_events_url":"https://api.github.com/users/SemanticMediaWiki/received_events","type":"Organization","site_admin":false},"repo":{"id":14058345,"name":"SemanticMediaWiki","full_name":"SemanticMediaWiki/SemanticMediaWiki","owner":{"login":"SemanticMediaWiki","id":1623598,"avatar_url":"https://avatars.githubusercontent.com/u/1623598?v=3","gravatar_id":"","url":"https://api.github.com/users/SemanticMediaWiki","html_url":"https://github.com/SemanticMediaWiki","followers_url":"https://api.github.com/users/SemanticMediaWiki/followers","following_url":"https://api.github.com/users/SemanticMediaWiki/following{/other_user}","gists_url":"https://api.github.com/users/SemanticMediaWiki/gists{/gist_id}","starred_url":"https://api.github.com/users/SemanticMediaWiki/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SemanticMediaWiki/subscriptions","organizations_url":"https://api.github.com/users/SemanticMediaWiki/orgs","repos_url":"https://api.github.com/users/SemanticMediaWiki/repos","events_url":"https://api.github.com/users/SemanticMediaWiki/events{/privacy}","received_events_url":"https://api.github.com/users/SemanticMediaWiki/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/SemanticMediaWiki/SemanticMediaWiki","description":"Semantic MediaWiki is a project for extending MediaWiki with \"semantic\" functions that enable machine-reading of wiki-content.","fork":false,"url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki","forks_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/forks","keys_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/keys{/key_id}","collaborators_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/teams","hooks_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/hooks","issue_events_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/issues/events{/number}","events_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/events","assignees_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/assignees{/user}","branches_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/branches{/branch}","tags_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/tags","blobs_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/git/refs{/sha}","trees_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/git/trees{/sha}","statuses_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/statuses/{sha}","languages_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/languages","stargazers_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/stargazers","contributors_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/contributors","subscribers_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/subscribers","subscription_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/subscription","commits_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/commits{/sha}","git_commits_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/git/commits{/sha}","comments_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/comments{/number}","issue_comment_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/issues/comments{/number}","contents_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/contents/{+path}","compare_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/compare/{base}...{head}","merges_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/merges","archive_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/downloads","issues_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/issues{/number}","pulls_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/pulls{/number}","milestones_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/milestones{/number}","notifications_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/labels{/name}","releases_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/releases{/id}","deployments_url":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/deployments","created_at":"2013-11-02T01:38:36Z","updated_at":"2016-06-12T18:45:19Z","pushed_at":"2016-06-22T00:19:42Z","git_url":"git://github.com/SemanticMediaWiki/SemanticMediaWiki.git","ssh_url":"git@github.com:SemanticMediaWiki/SemanticMediaWiki.git","clone_url":"https://github.com/SemanticMediaWiki/SemanticMediaWiki.git","svn_url":"https://github.com/SemanticMediaWiki/SemanticMediaWiki","homepage":"https://www.semantic-mediawiki.org/","size":25376,"stargazers_count":104,"watchers_count":104,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":71,"mirror_url":null,"open_issues_count":134,"forks":71,"open_issues":134,"watchers":104,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/pulls/1661"},"html":{"href":"https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/1661"},"issue":{"href":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/issues/1661"},"comments":{"href":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/issues/1661/comments"},"review_comments":{"href":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/pulls/1661/comments"},"review_comment":{"href":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/pulls/1661/commits"},"statuses":{"href":"https://api.github.com/repos/SemanticMediaWiki/SemanticMediaWiki/statuses/2e710024277c33c7a5d0cc8704b28585693f10c3"}}}}
{"actor":{"display_login":"mwjames"}}