{"action":"created","comment":{"url":"https://api.github.com/repos/aleien/Yapplication/pulls/comments/74474782","id":74474782,"diff_hunk":"@@ -0,0 +1,76 @@\n+package ru.aleien.yapplication.database;\n+\n+import org.junit.After;\n+import org.junit.Assert;\n+import org.junit.Before;\n+import org.junit.Test;\n+import org.junit.runner.RunWith;\n+import org.robolectric.RobolectricTestRunner;\n+import org.robolectric.RuntimeEnvironment;\n+import org.robolectric.annotation.Config;\n+\n+import java.util.ArrayList;\n+import java.util.List;\n+\n+import ru.aleien.yapplication.BuildConfig;\n+import ru.aleien.yapplication.model.Artist;\n+\n+/**\n+ * Created by aleien on 09.08.16.\n+ */\n+@RunWith(RobolectricTestRunner.class)\n+@Config(constants = BuildConfig.class, sdk = 23)\n+public class DBBackendTest {\n+    DBHelper dbHelper = new DBHelper(RuntimeEnvironment.application, \"testDB\");\n+    DBBackend dbBackend = new DBBackend(dbHelper);\n+\n+    @Before\n+    public void setUp() throws Exception {\n+\n+    }\n+\n+    @After\n+    public void tearDown() throws Exception {\n+        dbBackend.clearArtists();\n+\n+    }\n+\n+    @Test\n+    public void insertArtist() throws Exception {\n+        List<String> genres = new ArrayList<>();\n+        genres.add(\"pop\");\n+        genres.add(\"jazz\");\n+        Artist artist = new Artist(500, \"Tove Lo\", genres, 20, 2, \"http://lalala.com\", \"Description\", new Artist.Cover(\"http://firstimage\", \"http://seconimage\"));\n+        dbBackend.insertArtist(artist);\n+\n+        List<Artist> artists = dbBackend.loadArtists();\n+        Assert.assertEquals(artists.size(), 1);\n+//        Assert.assertTrue(artist.equals(artists.get(0)));","path":"app/src/test/java/ru/aleien/yapplication/database/DBBackendTest.java","position":48,"original_position":48,"commit_id":"049aefe7fe9181e3c46bb42c5775b6189f82ed2f","original_commit_id":"049aefe7fe9181e3c46bb42c5775b6189f82ed2f","user":{"login":"matreshkin","id":5363053,"avatar_url":"https://avatars.githubusercontent.com/u/5363053?v=3","gravatar_id":"","url":"https://api.github.com/users/matreshkin","html_url":"https://github.com/matreshkin","followers_url":"https://api.github.com/users/matreshkin/followers","following_url":"https://api.github.com/users/matreshkin/following{/other_user}","gists_url":"https://api.github.com/users/matreshkin/gists{/gist_id}","starred_url":"https://api.github.com/users/matreshkin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matreshkin/subscriptions","organizations_url":"https://api.github.com/users/matreshkin/orgs","repos_url":"https://api.github.com/users/matreshkin/repos","events_url":"https://api.github.com/users/matreshkin/events{/privacy}","received_events_url":"https://api.github.com/users/matreshkin/received_events","type":"User","site_admin":false},"body":"что тут не так?","created_at":"2016-08-11T18:18:57Z","updated_at":"2016-08-11T18:18:57Z","html_url":"https://github.com/aleien/Yapplication/pull/3#discussion_r74474782","pull_request_url":"https://api.github.com/repos/aleien/Yapplication/pulls/3","_links":{"self":{"href":"https://api.github.com/repos/aleien/Yapplication/pulls/comments/74474782"},"html":{"href":"https://github.com/aleien/Yapplication/pull/3#discussion_r74474782"},"pull_request":{"href":"https://api.github.com/repos/aleien/Yapplication/pulls/3"}}},"pull_request":{"url":"https://api.github.com/repos/aleien/Yapplication/pulls/3","id":80865301,"html_url":"https://github.com/aleien/Yapplication/pull/3","diff_url":"https://github.com/aleien/Yapplication/pull/3.diff","patch_url":"https://github.com/aleien/Yapplication/pull/3.patch","issue_url":"https://api.github.com/repos/aleien/Yapplication/issues/3","number":3,"state":"open","locked":false,"title":"Content provider","user":{"login":"aleien","id":7263920,"avatar_url":"https://avatars.githubusercontent.com/u/7263920?v=3","gravatar_id":"","url":"https://api.github.com/users/aleien","html_url":"https://github.com/aleien","followers_url":"https://api.github.com/users/aleien/followers","following_url":"https://api.github.com/users/aleien/following{/other_user}","gists_url":"https://api.github.com/users/aleien/gists{/gist_id}","starred_url":"https://api.github.com/users/aleien/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aleien/subscriptions","organizations_url":"https://api.github.com/users/aleien/orgs","repos_url":"https://api.github.com/users/aleien/repos","events_url":"https://api.github.com/users/aleien/events{/privacy}","received_events_url":"https://api.github.com/users/aleien/received_events","type":"User","site_admin":false},"body":"Пока тут не особо на что есть смотреть))","created_at":"2016-08-10T20:51:10Z","updated_at":"2016-08-11T18:18:57Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/aleien/Yapplication/pulls/3/commits","review_comments_url":"https://api.github.com/repos/aleien/Yapplication/pulls/3/comments","review_comment_url":"https://api.github.com/repos/aleien/Yapplication/pulls/comments{/number}","comments_url":"https://api.github.com/repos/aleien/Yapplication/issues/3/comments","statuses_url":"https://api.github.com/repos/aleien/Yapplication/statuses/049aefe7fe9181e3c46bb42c5775b6189f82ed2f","head":{"label":"aleien:content-provider","ref":"content-provider","sha":"049aefe7fe9181e3c46bb42c5775b6189f82ed2f","user":{"login":"aleien","id":7263920,"avatar_url":"https://avatars.githubusercontent.com/u/7263920?v=3","gravatar_id":"","url":"https://api.github.com/users/aleien","html_url":"https://github.com/aleien","followers_url":"https://api.github.com/users/aleien/followers","following_url":"https://api.github.com/users/aleien/following{/other_user}","gists_url":"https://api.github.com/users/aleien/gists{/gist_id}","starred_url":"https://api.github.com/users/aleien/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aleien/subscriptions","organizations_url":"https://api.github.com/users/aleien/orgs","repos_url":"https://api.github.com/users/aleien/repos","events_url":"https://api.github.com/users/aleien/events{/privacy}","received_events_url":"https://api.github.com/users/aleien/received_events","type":"User","site_admin":false},"repo":{"id":55579732,"name":"Yapplication","full_name":"aleien/Yapplication","owner":{"login":"aleien","id":7263920,"avatar_url":"https://avatars.githubusercontent.com/u/7263920?v=3","gravatar_id":"","url":"https://api.github.com/users/aleien","html_url":"https://github.com/aleien","followers_url":"https://api.github.com/users/aleien/followers","following_url":"https://api.github.com/users/aleien/following{/other_user}","gists_url":"https://api.github.com/users/aleien/gists{/gist_id}","starred_url":"https://api.github.com/users/aleien/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aleien/subscriptions","organizations_url":"https://api.github.com/users/aleien/orgs","repos_url":"https://api.github.com/users/aleien/repos","events_url":"https://api.github.com/users/aleien/events{/privacy}","received_events_url":"https://api.github.com/users/aleien/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/aleien/Yapplication","description":"","fork":false,"url":"https://api.github.com/repos/aleien/Yapplication","forks_url":"https://api.github.com/repos/aleien/Yapplication/forks","keys_url":"https://api.github.com/repos/aleien/Yapplication/keys{/key_id}","collaborators_url":"https://api.github.com/repos/aleien/Yapplication/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/aleien/Yapplication/teams","hooks_url":"https://api.github.com/repos/aleien/Yapplication/hooks","issue_events_url":"https://api.github.com/repos/aleien/Yapplication/issues/events{/number}","events_url":"https://api.github.com/repos/aleien/Yapplication/events","assignees_url":"https://api.github.com/repos/aleien/Yapplication/assignees{/user}","branches_url":"https://api.github.com/repos/aleien/Yapplication/branches{/branch}","tags_url":"https://api.github.com/repos/aleien/Yapplication/tags","blobs_url":"https://api.github.com/repos/aleien/Yapplication/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/aleien/Yapplication/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/aleien/Yapplication/git/refs{/sha}","trees_url":"https://api.github.com/repos/aleien/Yapplication/git/trees{/sha}","statuses_url":"https://api.github.com/repos/aleien/Yapplication/statuses/{sha}","languages_url":"https://api.github.com/repos/aleien/Yapplication/languages","stargazers_url":"https://api.github.com/repos/aleien/Yapplication/stargazers","contributors_url":"https://api.github.com/repos/aleien/Yapplication/contributors","subscribers_url":"https://api.github.com/repos/aleien/Yapplication/subscribers","subscription_url":"https://api.github.com/repos/aleien/Yapplication/subscription","commits_url":"https://api.github.com/repos/aleien/Yapplication/commits{/sha}","git_commits_url":"https://api.github.com/repos/aleien/Yapplication/git/commits{/sha}","comments_url":"https://api.github.com/repos/aleien/Yapplication/comments{/number}","issue_comment_url":"https://api.github.com/repos/aleien/Yapplication/issues/comments{/number}","contents_url":"https://api.github.com/repos/aleien/Yapplication/contents/{+path}","compare_url":"https://api.github.com/repos/aleien/Yapplication/compare/{base}...{head}","merges_url":"https://api.github.com/repos/aleien/Yapplication/merges","archive_url":"https://api.github.com/repos/aleien/Yapplication/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/aleien/Yapplication/downloads","issues_url":"https://api.github.com/repos/aleien/Yapplication/issues{/number}","pulls_url":"https://api.github.com/repos/aleien/Yapplication/pulls{/number}","milestones_url":"https://api.github.com/repos/aleien/Yapplication/milestones{/number}","notifications_url":"https://api.github.com/repos/aleien/Yapplication/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/aleien/Yapplication/labels{/name}","releases_url":"https://api.github.com/repos/aleien/Yapplication/releases{/id}","deployments_url":"https://api.github.com/repos/aleien/Yapplication/deployments","created_at":"2016-04-06T05:59:35Z","updated_at":"2016-04-10T08:09:38Z","pushed_at":"2016-08-10T20:51:10Z","git_url":"git://github.com/aleien/Yapplication.git","ssh_url":"git@github.com:aleien/Yapplication.git","clone_url":"https://github.com/aleien/Yapplication.git","svn_url":"https://github.com/aleien/Yapplication","homepage":null,"size":314,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":3,"forks":0,"open_issues":3,"watchers":0,"default_branch":"master"}},"base":{"label":"aleien:master","ref":"master","sha":"7d67036ab4da965f3efc428f28ebff57d766bf9a","user":{"login":"aleien","id":7263920,"avatar_url":"https://avatars.githubusercontent.com/u/7263920?v=3","gravatar_id":"","url":"https://api.github.com/users/aleien","html_url":"https://github.com/aleien","followers_url":"https://api.github.com/users/aleien/followers","following_url":"https://api.github.com/users/aleien/following{/other_user}","gists_url":"https://api.github.com/users/aleien/gists{/gist_id}","starred_url":"https://api.github.com/users/aleien/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aleien/subscriptions","organizations_url":"https://api.github.com/users/aleien/orgs","repos_url":"https://api.github.com/users/aleien/repos","events_url":"https://api.github.com/users/aleien/events{/privacy}","received_events_url":"https://api.github.com/users/aleien/received_events","type":"User","site_admin":false},"repo":{"id":55579732,"name":"Yapplication","full_name":"aleien/Yapplication","owner":{"login":"aleien","id":7263920,"avatar_url":"https://avatars.githubusercontent.com/u/7263920?v=3","gravatar_id":"","url":"https://api.github.com/users/aleien","html_url":"https://github.com/aleien","followers_url":"https://api.github.com/users/aleien/followers","following_url":"https://api.github.com/users/aleien/following{/other_user}","gists_url":"https://api.github.com/users/aleien/gists{/gist_id}","starred_url":"https://api.github.com/users/aleien/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aleien/subscriptions","organizations_url":"https://api.github.com/users/aleien/orgs","repos_url":"https://api.github.com/users/aleien/repos","events_url":"https://api.github.com/users/aleien/events{/privacy}","received_events_url":"https://api.github.com/users/aleien/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/aleien/Yapplication","description":"","fork":false,"url":"https://api.github.com/repos/aleien/Yapplication","forks_url":"https://api.github.com/repos/aleien/Yapplication/forks","keys_url":"https://api.github.com/repos/aleien/Yapplication/keys{/key_id}","collaborators_url":"https://api.github.com/repos/aleien/Yapplication/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/aleien/Yapplication/teams","hooks_url":"https://api.github.com/repos/aleien/Yapplication/hooks","issue_events_url":"https://api.github.com/repos/aleien/Yapplication/issues/events{/number}","events_url":"https://api.github.com/repos/aleien/Yapplication/events","assignees_url":"https://api.github.com/repos/aleien/Yapplication/assignees{/user}","branches_url":"https://api.github.com/repos/aleien/Yapplication/branches{/branch}","tags_url":"https://api.github.com/repos/aleien/Yapplication/tags","blobs_url":"https://api.github.com/repos/aleien/Yapplication/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/aleien/Yapplication/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/aleien/Yapplication/git/refs{/sha}","trees_url":"https://api.github.com/repos/aleien/Yapplication/git/trees{/sha}","statuses_url":"https://api.github.com/repos/aleien/Yapplication/statuses/{sha}","languages_url":"https://api.github.com/repos/aleien/Yapplication/languages","stargazers_url":"https://api.github.com/repos/aleien/Yapplication/stargazers","contributors_url":"https://api.github.com/repos/aleien/Yapplication/contributors","subscribers_url":"https://api.github.com/repos/aleien/Yapplication/subscribers","subscription_url":"https://api.github.com/repos/aleien/Yapplication/subscription","commits_url":"https://api.github.com/repos/aleien/Yapplication/commits{/sha}","git_commits_url":"https://api.github.com/repos/aleien/Yapplication/git/commits{/sha}","comments_url":"https://api.github.com/repos/aleien/Yapplication/comments{/number}","issue_comment_url":"https://api.github.com/repos/aleien/Yapplication/issues/comments{/number}","contents_url":"https://api.github.com/repos/aleien/Yapplication/contents/{+path}","compare_url":"https://api.github.com/repos/aleien/Yapplication/compare/{base}...{head}","merges_url":"https://api.github.com/repos/aleien/Yapplication/merges","archive_url":"https://api.github.com/repos/aleien/Yapplication/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/aleien/Yapplication/downloads","issues_url":"https://api.github.com/repos/aleien/Yapplication/issues{/number}","pulls_url":"https://api.github.com/repos/aleien/Yapplication/pulls{/number}","milestones_url":"https://api.github.com/repos/aleien/Yapplication/milestones{/number}","notifications_url":"https://api.github.com/repos/aleien/Yapplication/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/aleien/Yapplication/labels{/name}","releases_url":"https://api.github.com/repos/aleien/Yapplication/releases{/id}","deployments_url":"https://api.github.com/repos/aleien/Yapplication/deployments","created_at":"2016-04-06T05:59:35Z","updated_at":"2016-04-10T08:09:38Z","pushed_at":"2016-08-10T20:51:10Z","git_url":"git://github.com/aleien/Yapplication.git","ssh_url":"git@github.com:aleien/Yapplication.git","clone_url":"https://github.com/aleien/Yapplication.git","svn_url":"https://github.com/aleien/Yapplication","homepage":null,"size":314,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":3,"forks":0,"open_issues":3,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/aleien/Yapplication/pulls/3"},"html":{"href":"https://github.com/aleien/Yapplication/pull/3"},"issue":{"href":"https://api.github.com/repos/aleien/Yapplication/issues/3"},"comments":{"href":"https://api.github.com/repos/aleien/Yapplication/issues/3/comments"},"review_comments":{"href":"https://api.github.com/repos/aleien/Yapplication/pulls/3/comments"},"review_comment":{"href":"https://api.github.com/repos/aleien/Yapplication/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/aleien/Yapplication/pulls/3/commits"},"statuses":{"href":"https://api.github.com/repos/aleien/Yapplication/statuses/049aefe7fe9181e3c46bb42c5775b6189f82ed2f"}}}}
{"actor":{"display_login":"matreshkin"}}