{"action":"created","comment":{"url":"https://api.github.com/repos/citra-emu/hwtests/pulls/comments/25122537","id":25122537,"diff_hunk":"@@ -0,0 +1,68 @@\n+#include <array>\n+#include <3ds.h>\n+\n+#include \"common/result.h\"\n+#include \"output.h\"\n+#include \"tests/test.h\"\n+#include \"tests/cfg/cfg.h\"\n+\n+namespace Cfg {\n+\n+    template <u32 Id, u16 Size>\n+    struct CfgBlock {\n+        static const u32 id = Id;\n+        static const u16 size = Size;\n+    };\n+\n+    // A valid block\n+    static const CfgBlock<0x000B0000, 0x4> BLK_COUNTRY_INFO;\n+\n+    // Invalid due to wrong size\n+    static const CfgBlock<0x000B0000, 0x8> INVALID_COUNTRY_INFO_SIZE;\n+\n+    // This block does not have a valid ID\n+    static const CfgBlock<0x01160500, 0x1> INVALID_ID;\n+\n+    // Expected errors\n+    const ResultCode RC_BAD_SIZE =\n+        ResultCode(ErrorDescription::InvalidSize, ErrorModule::Config, ErrorSummary::WrongArgument, ErrorLevel::Permanent);\n+\n+    const ResultCode RC_BAD_ID =\n+        ResultCode(ErrorDescription::NotFound, ErrorModule::Config, ErrorSummary::WrongArgument, ErrorLevel::Permanent);\n+\n+\n+    static bool TestCfgBlockNotFoundRC() {\n+        const u32 blkID = INVALID_ID.id;\n+        const u32 size = INVALID_ID.size;\n+        std::array<u8, size> outData;\n+\n+        Result result = CFGU_GetConfigInfoBlk2(size, blkID, &outData[0]);\n+\n+        if ((u32)result != RC_BAD_ID.raw)","path":"source/tests/cfg/cfg.cpp","position":41,"original_position":41,"commit_id":"8b2f7a5b6707af89e231522ad3ce41e5d8fe05cf","original_commit_id":"8b2f7a5b6707af89e231522ad3ce41e5d8fe05cf","user":{"login":"Subv","id":357072,"avatar_url":"https://avatars.githubusercontent.com/u/357072?v=3","gravatar_id":"","url":"https://api.github.com/users/Subv","html_url":"https://github.com/Subv","followers_url":"https://api.github.com/users/Subv/followers","following_url":"https://api.github.com/users/Subv/following{/other_user}","gists_url":"https://api.github.com/users/Subv/gists{/gist_id}","starred_url":"https://api.github.com/users/Subv/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Subv/subscriptions","organizations_url":"https://api.github.com/users/Subv/orgs","repos_url":"https://api.github.com/users/Subv/repos","events_url":"https://api.github.com/users/Subv/events{/privacy}","received_events_url":"https://api.github.com/users/Subv/received_events","type":"User","site_admin":false},"body":"Shouldn't you use SoftAssert for this?","created_at":"2015-02-21T14:37:52Z","updated_at":"2015-02-21T14:37:52Z","html_url":"https://github.com/citra-emu/hwtests/pull/26#discussion_r25122537","pull_request_url":"https://api.github.com/repos/citra-emu/hwtests/pulls/26","_links":{"self":{"href":"https://api.github.com/repos/citra-emu/hwtests/pulls/comments/25122537"},"html":{"href":"https://github.com/citra-emu/hwtests/pull/26#discussion_r25122537"},"pull_request":{"href":"https://api.github.com/repos/citra-emu/hwtests/pulls/26"}}},"pull_request":{"url":"https://api.github.com/repos/citra-emu/hwtests/pulls/26","id":29749390,"html_url":"https://github.com/citra-emu/hwtests/pull/26","diff_url":"https://github.com/citra-emu/hwtests/pull/26.diff","patch_url":"https://github.com/citra-emu/hwtests/pull/26.patch","issue_url":"https://api.github.com/repos/citra-emu/hwtests/issues/26","number":26,"state":"open","locked":false,"title":"Cfg error code tests","user":{"login":"kevinhartman","id":1374024,"avatar_url":"https://avatars.githubusercontent.com/u/1374024?v=3","gravatar_id":"","url":"https://api.github.com/users/kevinhartman","html_url":"https://github.com/kevinhartman","followers_url":"https://api.github.com/users/kevinhartman/followers","following_url":"https://api.github.com/users/kevinhartman/following{/other_user}","gists_url":"https://api.github.com/users/kevinhartman/gists{/gist_id}","starred_url":"https://api.github.com/users/kevinhartman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kevinhartman/subscriptions","organizations_url":"https://api.github.com/users/kevinhartman/orgs","repos_url":"https://api.github.com/users/kevinhartman/repos","events_url":"https://api.github.com/users/kevinhartman/events{/privacy}","received_events_url":"https://api.github.com/users/kevinhartman/received_events","type":"User","site_admin":false},"body":"Changes include:\r\n* Cfg error code tests for invalid size and unknown block ID\r\n* result.h and bitfield.h along with some of their dependencies\r\n\r\n<b>Note:</b> I removed ResultVal from result.h as it doesn't really make sense client side, and iirc requires more dependencies. I also removed some includes from common.h to avoid bringing in unneeded dependencies.","created_at":"2015-02-21T05:46:19Z","updated_at":"2015-02-21T14:37:52Z","closed_at":null,"merged_at":null,"merge_commit_sha":"b1aa6cfb0bc6ce561a3c535f9a3fc5e00ac34ed3","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/citra-emu/hwtests/pulls/26/commits","review_comments_url":"https://api.github.com/repos/citra-emu/hwtests/pulls/26/comments","review_comment_url":"https://api.github.com/repos/citra-emu/hwtests/pulls/comments/{number}","comments_url":"https://api.github.com/repos/citra-emu/hwtests/issues/26/comments","statuses_url":"https://api.github.com/repos/citra-emu/hwtests/statuses/8b2f7a5b6707af89e231522ad3ce41e5d8fe05cf","head":{"label":"kevinhartman:master","ref":"master","sha":"8b2f7a5b6707af89e231522ad3ce41e5d8fe05cf","user":{"login":"kevinhartman","id":1374024,"avatar_url":"https://avatars.githubusercontent.com/u/1374024?v=3","gravatar_id":"","url":"https://api.github.com/users/kevinhartman","html_url":"https://github.com/kevinhartman","followers_url":"https://api.github.com/users/kevinhartman/followers","following_url":"https://api.github.com/users/kevinhartman/following{/other_user}","gists_url":"https://api.github.com/users/kevinhartman/gists{/gist_id}","starred_url":"https://api.github.com/users/kevinhartman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kevinhartman/subscriptions","organizations_url":"https://api.github.com/users/kevinhartman/orgs","repos_url":"https://api.github.com/users/kevinhartman/repos","events_url":"https://api.github.com/users/kevinhartman/events{/privacy}","received_events_url":"https://api.github.com/users/kevinhartman/received_events","type":"User","site_admin":false},"repo":{"id":31115874,"name":"hwtests","full_name":"kevinhartman/hwtests","owner":{"login":"kevinhartman","id":1374024,"avatar_url":"https://avatars.githubusercontent.com/u/1374024?v=3","gravatar_id":"","url":"https://api.github.com/users/kevinhartman","html_url":"https://github.com/kevinhartman","followers_url":"https://api.github.com/users/kevinhartman/followers","following_url":"https://api.github.com/users/kevinhartman/following{/other_user}","gists_url":"https://api.github.com/users/kevinhartman/gists{/gist_id}","starred_url":"https://api.github.com/users/kevinhartman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kevinhartman/subscriptions","organizations_url":"https://api.github.com/users/kevinhartman/orgs","repos_url":"https://api.github.com/users/kevinhartman/repos","events_url":"https://api.github.com/users/kevinhartman/events{/privacy}","received_events_url":"https://api.github.com/users/kevinhartman/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/kevinhartman/hwtests","description":"Beginnings of a hwtest suite for Citra","fork":true,"url":"https://api.github.com/repos/kevinhartman/hwtests","forks_url":"https://api.github.com/repos/kevinhartman/hwtests/forks","keys_url":"https://api.github.com/repos/kevinhartman/hwtests/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kevinhartman/hwtests/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kevinhartman/hwtests/teams","hooks_url":"https://api.github.com/repos/kevinhartman/hwtests/hooks","issue_events_url":"https://api.github.com/repos/kevinhartman/hwtests/issues/events{/number}","events_url":"https://api.github.com/repos/kevinhartman/hwtests/events","assignees_url":"https://api.github.com/repos/kevinhartman/hwtests/assignees{/user}","branches_url":"https://api.github.com/repos/kevinhartman/hwtests/branches{/branch}","tags_url":"https://api.github.com/repos/kevinhartman/hwtests/tags","blobs_url":"https://api.github.com/repos/kevinhartman/hwtests/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kevinhartman/hwtests/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kevinhartman/hwtests/git/refs{/sha}","trees_url":"https://api.github.com/repos/kevinhartman/hwtests/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kevinhartman/hwtests/statuses/{sha}","languages_url":"https://api.github.com/repos/kevinhartman/hwtests/languages","stargazers_url":"https://api.github.com/repos/kevinhartman/hwtests/stargazers","contributors_url":"https://api.github.com/repos/kevinhartman/hwtests/contributors","subscribers_url":"https://api.github.com/repos/kevinhartman/hwtests/subscribers","subscription_url":"https://api.github.com/repos/kevinhartman/hwtests/subscription","commits_url":"https://api.github.com/repos/kevinhartman/hwtests/commits{/sha}","git_commits_url":"https://api.github.com/repos/kevinhartman/hwtests/git/commits{/sha}","comments_url":"https://api.github.com/repos/kevinhartman/hwtests/comments{/number}","issue_comment_url":"https://api.github.com/repos/kevinhartman/hwtests/issues/comments/{number}","contents_url":"https://api.github.com/repos/kevinhartman/hwtests/contents/{+path}","compare_url":"https://api.github.com/repos/kevinhartman/hwtests/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kevinhartman/hwtests/merges","archive_url":"https://api.github.com/repos/kevinhartman/hwtests/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kevinhartman/hwtests/downloads","issues_url":"https://api.github.com/repos/kevinhartman/hwtests/issues{/number}","pulls_url":"https://api.github.com/repos/kevinhartman/hwtests/pulls{/number}","milestones_url":"https://api.github.com/repos/kevinhartman/hwtests/milestones{/number}","notifications_url":"https://api.github.com/repos/kevinhartman/hwtests/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kevinhartman/hwtests/labels{/name}","releases_url":"https://api.github.com/repos/kevinhartman/hwtests/releases{/id}","created_at":"2015-02-21T05:00:15Z","updated_at":"2015-02-21T08:53:00Z","pushed_at":"2015-02-21T08:53:00Z","git_url":"git://github.com/kevinhartman/hwtests.git","ssh_url":"git@github.com:kevinhartman/hwtests.git","clone_url":"https://github.com/kevinhartman/hwtests.git","svn_url":"https://github.com/kevinhartman/hwtests","homepage":"http://citra-emu.org","size":188,"stargazers_count":0,"watchers_count":0,"language":"C++","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":"citra-emu:master","ref":"master","sha":"2e2211182060bfcf30dc88d30f1ef0b97b9d5df5","user":{"login":"citra-emu","id":7605670,"avatar_url":"https://avatars.githubusercontent.com/u/7605670?v=3","gravatar_id":"","url":"https://api.github.com/users/citra-emu","html_url":"https://github.com/citra-emu","followers_url":"https://api.github.com/users/citra-emu/followers","following_url":"https://api.github.com/users/citra-emu/following{/other_user}","gists_url":"https://api.github.com/users/citra-emu/gists{/gist_id}","starred_url":"https://api.github.com/users/citra-emu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/citra-emu/subscriptions","organizations_url":"https://api.github.com/users/citra-emu/orgs","repos_url":"https://api.github.com/users/citra-emu/repos","events_url":"https://api.github.com/users/citra-emu/events{/privacy}","received_events_url":"https://api.github.com/users/citra-emu/received_events","type":"Organization","site_admin":false},"repo":{"id":27095065,"name":"hwtests","full_name":"citra-emu/hwtests","owner":{"login":"citra-emu","id":7605670,"avatar_url":"https://avatars.githubusercontent.com/u/7605670?v=3","gravatar_id":"","url":"https://api.github.com/users/citra-emu","html_url":"https://github.com/citra-emu","followers_url":"https://api.github.com/users/citra-emu/followers","following_url":"https://api.github.com/users/citra-emu/following{/other_user}","gists_url":"https://api.github.com/users/citra-emu/gists{/gist_id}","starred_url":"https://api.github.com/users/citra-emu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/citra-emu/subscriptions","organizations_url":"https://api.github.com/users/citra-emu/orgs","repos_url":"https://api.github.com/users/citra-emu/repos","events_url":"https://api.github.com/users/citra-emu/events{/privacy}","received_events_url":"https://api.github.com/users/citra-emu/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/citra-emu/hwtests","description":"Beginnings of a hwtest suite for Citra","fork":false,"url":"https://api.github.com/repos/citra-emu/hwtests","forks_url":"https://api.github.com/repos/citra-emu/hwtests/forks","keys_url":"https://api.github.com/repos/citra-emu/hwtests/keys{/key_id}","collaborators_url":"https://api.github.com/repos/citra-emu/hwtests/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/citra-emu/hwtests/teams","hooks_url":"https://api.github.com/repos/citra-emu/hwtests/hooks","issue_events_url":"https://api.github.com/repos/citra-emu/hwtests/issues/events{/number}","events_url":"https://api.github.com/repos/citra-emu/hwtests/events","assignees_url":"https://api.github.com/repos/citra-emu/hwtests/assignees{/user}","branches_url":"https://api.github.com/repos/citra-emu/hwtests/branches{/branch}","tags_url":"https://api.github.com/repos/citra-emu/hwtests/tags","blobs_url":"https://api.github.com/repos/citra-emu/hwtests/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/citra-emu/hwtests/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/citra-emu/hwtests/git/refs{/sha}","trees_url":"https://api.github.com/repos/citra-emu/hwtests/git/trees{/sha}","statuses_url":"https://api.github.com/repos/citra-emu/hwtests/statuses/{sha}","languages_url":"https://api.github.com/repos/citra-emu/hwtests/languages","stargazers_url":"https://api.github.com/repos/citra-emu/hwtests/stargazers","contributors_url":"https://api.github.com/repos/citra-emu/hwtests/contributors","subscribers_url":"https://api.github.com/repos/citra-emu/hwtests/subscribers","subscription_url":"https://api.github.com/repos/citra-emu/hwtests/subscription","commits_url":"https://api.github.com/repos/citra-emu/hwtests/commits{/sha}","git_commits_url":"https://api.github.com/repos/citra-emu/hwtests/git/commits{/sha}","comments_url":"https://api.github.com/repos/citra-emu/hwtests/comments{/number}","issue_comment_url":"https://api.github.com/repos/citra-emu/hwtests/issues/comments/{number}","contents_url":"https://api.github.com/repos/citra-emu/hwtests/contents/{+path}","compare_url":"https://api.github.com/repos/citra-emu/hwtests/compare/{base}...{head}","merges_url":"https://api.github.com/repos/citra-emu/hwtests/merges","archive_url":"https://api.github.com/repos/citra-emu/hwtests/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/citra-emu/hwtests/downloads","issues_url":"https://api.github.com/repos/citra-emu/hwtests/issues{/number}","pulls_url":"https://api.github.com/repos/citra-emu/hwtests/pulls{/number}","milestones_url":"https://api.github.com/repos/citra-emu/hwtests/milestones{/number}","notifications_url":"https://api.github.com/repos/citra-emu/hwtests/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/citra-emu/hwtests/labels{/name}","releases_url":"https://api.github.com/repos/citra-emu/hwtests/releases{/id}","created_at":"2014-11-24T21:03:20Z","updated_at":"2015-02-13T20:17:58Z","pushed_at":"2015-02-13T05:21:33Z","git_url":"git://github.com/citra-emu/hwtests.git","ssh_url":"git@github.com:citra-emu/hwtests.git","clone_url":"https://github.com/citra-emu/hwtests.git","svn_url":"https://github.com/citra-emu/hwtests","homepage":"http://citra-emu.org","size":520,"stargazers_count":2,"watchers_count":2,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":8,"mirror_url":null,"open_issues_count":2,"forks":8,"open_issues":2,"watchers":2,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/citra-emu/hwtests/pulls/26"},"html":{"href":"https://github.com/citra-emu/hwtests/pull/26"},"issue":{"href":"https://api.github.com/repos/citra-emu/hwtests/issues/26"},"comments":{"href":"https://api.github.com/repos/citra-emu/hwtests/issues/26/comments"},"review_comments":{"href":"https://api.github.com/repos/citra-emu/hwtests/pulls/26/comments"},"review_comment":{"href":"https://api.github.com/repos/citra-emu/hwtests/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/citra-emu/hwtests/pulls/26/commits"},"statuses":{"href":"https://api.github.com/repos/citra-emu/hwtests/statuses/8b2f7a5b6707af89e231522ad3ce41e5d8fe05cf"}}}}