{"action":"created","comment":{"url":"https://api.github.com/repos/tangrams/tangram-es/pulls/comments/219941066","pull_request_review_id":158235597,"id":219941066,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIxOTk0MTA2Ng==","diff_hunk":"@@ -0,0 +1,134 @@\n+#include \"catch.hpp\"\n+\n+#include \"util/yamlUtil.h\"\n+\n+using namespace Tangram;\n+\n+TEST_CASE(\"YamlUtil functions correctly handle scalar node\", \"[YamlUtil]\") {\n+\n+    float defaultFloat = 12345.67f, initialFloat = 76.54321f, resultFloat = initialFloat;\n+    double defaultDouble = 12345.67, initialDouble = 76.54321, resultDouble = initialDouble;\n+    bool defaultBool = true, initialBool = false, resultBool = initialBool;\n+\n+    SECTION(\"Empty String Node\") {\n+        YAML::Node node(\"\");\n+\n+        CHECK_FALSE(YamlUtil::getFloat(node, resultFloat));\n+        CHECK(resultFloat == initialFloat);\n+        CHECK(YamlUtil::getFloatOrDefault(node, defaultFloat) == defaultFloat);\n+\n+        CHECK_FALSE(YamlUtil::getDouble(node, resultDouble));\n+        CHECK(resultDouble == initialDouble);\n+        CHECK(YamlUtil::getDoubleOrDefault(node, defaultDouble) == defaultDouble);\n+\n+        CHECK_FALSE(YamlUtil::getBool(node, resultBool));\n+        CHECK(resultBool == initialBool);\n+        CHECK(YamlUtil::getBoolOrDefault(node, defaultBool) == defaultBool);\n+    }\n+\n+    SECTION(\"String Node\") {\n+        YAML::Node node(\"I saw 3 ships go sailing by\");","path":"tests/unit/yamlUtilTests.cpp","position":35,"original_position":30,"commit_id":"553d8114150a0da86be02e8d89aa251a4e533e98","original_commit_id":"b76e1c9a0d5e7177848398a8471c7999046a44c1","user":{"login":"tallytalwar","id":360641,"node_id":"MDQ6VXNlcjM2MDY0MQ==","avatar_url":"https://avatars2.githubusercontent.com/u/360641?v=4","gravatar_id":"","url":"https://api.github.com/users/tallytalwar","html_url":"https://github.com/tallytalwar","followers_url":"https://api.github.com/users/tallytalwar/followers","following_url":"https://api.github.com/users/tallytalwar/following{/other_user}","gists_url":"https://api.github.com/users/tallytalwar/gists{/gist_id}","starred_url":"https://api.github.com/users/tallytalwar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tallytalwar/subscriptions","organizations_url":"https://api.github.com/users/tallytalwar/orgs","repos_url":"https://api.github.com/users/tallytalwar/repos","events_url":"https://api.github.com/users/tallytalwar/events{/privacy}","received_events_url":"https://api.github.com/users/tallytalwar/received_events","type":"User","site_admin":false},"body":"🌊 🚢 🚢 🚢 🌊 ","created_at":"2018-09-24T18:27:49Z","updated_at":"2018-09-24T18:27:49Z","html_url":"https://github.com/tangrams/tangram-es/pull/1874#discussion_r219941066","pull_request_url":"https://api.github.com/repos/tangrams/tangram-es/pulls/1874","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/tangrams/tangram-es/pulls/comments/219941066"},"html":{"href":"https://github.com/tangrams/tangram-es/pull/1874#discussion_r219941066"},"pull_request":{"href":"https://api.github.com/repos/tangrams/tangram-es/pulls/1874"}}},"pull_request":{"url":"https://api.github.com/repos/tangrams/tangram-es/pulls/1874","id":215797636,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE1Nzk3NjM2","html_url":"https://github.com/tangrams/tangram-es/pull/1874","diff_url":"https://github.com/tangrams/tangram-es/pull/1874.diff","patch_url":"https://github.com/tangrams/tangram-es/pull/1874.patch","issue_url":"https://api.github.com/repos/tangrams/tangram-es/issues/1874","number":1874,"state":"open","locked":false,"title":"Create a YamlUtil namespace of conversion functions","user":{"login":"matteblair","id":3371850,"node_id":"MDQ6VXNlcjMzNzE4NTA=","avatar_url":"https://avatars2.githubusercontent.com/u/3371850?v=4","gravatar_id":"","url":"https://api.github.com/users/matteblair","html_url":"https://github.com/matteblair","followers_url":"https://api.github.com/users/matteblair/followers","following_url":"https://api.github.com/users/matteblair/following{/other_user}","gists_url":"https://api.github.com/users/matteblair/gists{/gist_id}","starred_url":"https://api.github.com/users/matteblair/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matteblair/subscriptions","organizations_url":"https://api.github.com/users/matteblair/orgs","repos_url":"https://api.github.com/users/matteblair/repos","events_url":"https://api.github.com/users/matteblair/events{/privacy}","received_events_url":"https://api.github.com/users/matteblair/received_events","type":"User","site_admin":false},"body":"Allows us to share common conversion functions that\r\n- check node types\r\n- check conversion validity\r\n- avoid slow paths in YamlCpp\r\n\r\nWe should prefer these functions to `YAML::convert<T>::decode` (which is slow to parse numbers) and `node.as<T>` (which is slow to parse numbers _and_ throws conversion exceptions).","created_at":"2018-09-16T01:29:17Z","updated_at":"2018-09-24T18:27:49Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e8e74b092f8a2afbae76e47b79e06717005bc3f1","assignee":{"login":"tallytalwar","id":360641,"node_id":"MDQ6VXNlcjM2MDY0MQ==","avatar_url":"https://avatars2.githubusercontent.com/u/360641?v=4","gravatar_id":"","url":"https://api.github.com/users/tallytalwar","html_url":"https://github.com/tallytalwar","followers_url":"https://api.github.com/users/tallytalwar/followers","following_url":"https://api.github.com/users/tallytalwar/following{/other_user}","gists_url":"https://api.github.com/users/tallytalwar/gists{/gist_id}","starred_url":"https://api.github.com/users/tallytalwar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tallytalwar/subscriptions","organizations_url":"https://api.github.com/users/tallytalwar/orgs","repos_url":"https://api.github.com/users/tallytalwar/repos","events_url":"https://api.github.com/users/tallytalwar/events{/privacy}","received_events_url":"https://api.github.com/users/tallytalwar/received_events","type":"User","site_admin":false},"assignees":[{"login":"tallytalwar","id":360641,"node_id":"MDQ6VXNlcjM2MDY0MQ==","avatar_url":"https://avatars2.githubusercontent.com/u/360641?v=4","gravatar_id":"","url":"https://api.github.com/users/tallytalwar","html_url":"https://github.com/tallytalwar","followers_url":"https://api.github.com/users/tallytalwar/followers","following_url":"https://api.github.com/users/tallytalwar/following{/other_user}","gists_url":"https://api.github.com/users/tallytalwar/gists{/gist_id}","starred_url":"https://api.github.com/users/tallytalwar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tallytalwar/subscriptions","organizations_url":"https://api.github.com/users/tallytalwar/orgs","repos_url":"https://api.github.com/users/tallytalwar/repos","events_url":"https://api.github.com/users/tallytalwar/events{/privacy}","received_events_url":"https://api.github.com/users/tallytalwar/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/tangrams/tangram-es/pulls/1874/commits","review_comments_url":"https://api.github.com/repos/tangrams/tangram-es/pulls/1874/comments","review_comment_url":"https://api.github.com/repos/tangrams/tangram-es/pulls/comments{/number}","comments_url":"https://api.github.com/repos/tangrams/tangram-es/issues/1874/comments","statuses_url":"https://api.github.com/repos/tangrams/tangram-es/statuses/553d8114150a0da86be02e8d89aa251a4e533e98","head":{"label":"tangrams:yaml-util","ref":"yaml-util","sha":"553d8114150a0da86be02e8d89aa251a4e533e98","user":{"login":"tangrams","id":8495302,"node_id":"MDEyOk9yZ2FuaXphdGlvbjg0OTUzMDI=","avatar_url":"https://avatars2.githubusercontent.com/u/8495302?v=4","gravatar_id":"","url":"https://api.github.com/users/tangrams","html_url":"https://github.com/tangrams","followers_url":"https://api.github.com/users/tangrams/followers","following_url":"https://api.github.com/users/tangrams/following{/other_user}","gists_url":"https://api.github.com/users/tangrams/gists{/gist_id}","starred_url":"https://api.github.com/users/tangrams/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tangrams/subscriptions","organizations_url":"https://api.github.com/users/tangrams/orgs","repos_url":"https://api.github.com/users/tangrams/repos","events_url":"https://api.github.com/users/tangrams/events{/privacy}","received_events_url":"https://api.github.com/users/tangrams/received_events","type":"Organization","site_admin":false},"repo":{"id":23391501,"node_id":"MDEwOlJlcG9zaXRvcnkyMzM5MTUwMQ==","name":"tangram-es","full_name":"tangrams/tangram-es","private":false,"owner":{"login":"tangrams","id":8495302,"node_id":"MDEyOk9yZ2FuaXphdGlvbjg0OTUzMDI=","avatar_url":"https://avatars2.githubusercontent.com/u/8495302?v=4","gravatar_id":"","url":"https://api.github.com/users/tangrams","html_url":"https://github.com/tangrams","followers_url":"https://api.github.com/users/tangrams/followers","following_url":"https://api.github.com/users/tangrams/following{/other_user}","gists_url":"https://api.github.com/users/tangrams/gists{/gist_id}","starred_url":"https://api.github.com/users/tangrams/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tangrams/subscriptions","organizations_url":"https://api.github.com/users/tangrams/orgs","repos_url":"https://api.github.com/users/tangrams/repos","events_url":"https://api.github.com/users/tangrams/events{/privacy}","received_events_url":"https://api.github.com/users/tangrams/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/tangrams/tangram-es","description":"2D and 3D map renderer using OpenGL ES","fork":false,"url":"https://api.github.com/repos/tangrams/tangram-es","forks_url":"https://api.github.com/repos/tangrams/tangram-es/forks","keys_url":"https://api.github.com/repos/tangrams/tangram-es/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tangrams/tangram-es/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tangrams/tangram-es/teams","hooks_url":"https://api.github.com/repos/tangrams/tangram-es/hooks","issue_events_url":"https://api.github.com/repos/tangrams/tangram-es/issues/events{/number}","events_url":"https://api.github.com/repos/tangrams/tangram-es/events","assignees_url":"https://api.github.com/repos/tangrams/tangram-es/assignees{/user}","branches_url":"https://api.github.com/repos/tangrams/tangram-es/branches{/branch}","tags_url":"https://api.github.com/repos/tangrams/tangram-es/tags","blobs_url":"https://api.github.com/repos/tangrams/tangram-es/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tangrams/tangram-es/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tangrams/tangram-es/git/refs{/sha}","trees_url":"https://api.github.com/repos/tangrams/tangram-es/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tangrams/tangram-es/statuses/{sha}","languages_url":"https://api.github.com/repos/tangrams/tangram-es/languages","stargazers_url":"https://api.github.com/repos/tangrams/tangram-es/stargazers","contributors_url":"https://api.github.com/repos/tangrams/tangram-es/contributors","subscribers_url":"https://api.github.com/repos/tangrams/tangram-es/subscribers","subscription_url":"https://api.github.com/repos/tangrams/tangram-es/subscription","commits_url":"https://api.github.com/repos/tangrams/tangram-es/commits{/sha}","git_commits_url":"https://api.github.com/repos/tangrams/tangram-es/git/commits{/sha}","comments_url":"https://api.github.com/repos/tangrams/tangram-es/comments{/number}","issue_comment_url":"https://api.github.com/repos/tangrams/tangram-es/issues/comments{/number}","contents_url":"https://api.github.com/repos/tangrams/tangram-es/contents/{+path}","compare_url":"https://api.github.com/repos/tangrams/tangram-es/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tangrams/tangram-es/merges","archive_url":"https://api.github.com/repos/tangrams/tangram-es/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tangrams/tangram-es/downloads","issues_url":"https://api.github.com/repos/tangrams/tangram-es/issues{/number}","pulls_url":"https://api.github.com/repos/tangrams/tangram-es/pulls{/number}","milestones_url":"https://api.github.com/repos/tangrams/tangram-es/milestones{/number}","notifications_url":"https://api.github.com/repos/tangrams/tangram-es/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tangrams/tangram-es/labels{/name}","releases_url":"https://api.github.com/repos/tangrams/tangram-es/releases{/id}","deployments_url":"https://api.github.com/repos/tangrams/tangram-es/deployments","created_at":"2014-08-27T13:56:56Z","updated_at":"2018-09-23T18:28:07Z","pushed_at":"2018-09-22T13:58:15Z","git_url":"git://github.com/tangrams/tangram-es.git","ssh_url":"git@github.com:tangrams/tangram-es.git","clone_url":"https://github.com/tangrams/tangram-es.git","svn_url":"https://github.com/tangrams/tangram-es","homepage":"","size":36971,"stargazers_count":442,"watchers_count":442,"language":"C++","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":151,"mirror_url":null,"archived":false,"open_issues_count":138,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":151,"open_issues":138,"watchers":442,"default_branch":"master"}},"base":{"label":"tangrams:master","ref":"master","sha":"361c8c7dba906f0bcb0085013561c3be52cfbb0f","user":{"login":"tangrams","id":8495302,"node_id":"MDEyOk9yZ2FuaXphdGlvbjg0OTUzMDI=","avatar_url":"https://avatars2.githubusercontent.com/u/8495302?v=4","gravatar_id":"","url":"https://api.github.com/users/tangrams","html_url":"https://github.com/tangrams","followers_url":"https://api.github.com/users/tangrams/followers","following_url":"https://api.github.com/users/tangrams/following{/other_user}","gists_url":"https://api.github.com/users/tangrams/gists{/gist_id}","starred_url":"https://api.github.com/users/tangrams/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tangrams/subscriptions","organizations_url":"https://api.github.com/users/tangrams/orgs","repos_url":"https://api.github.com/users/tangrams/repos","events_url":"https://api.github.com/users/tangrams/events{/privacy}","received_events_url":"https://api.github.com/users/tangrams/received_events","type":"Organization","site_admin":false},"repo":{"id":23391501,"node_id":"MDEwOlJlcG9zaXRvcnkyMzM5MTUwMQ==","name":"tangram-es","full_name":"tangrams/tangram-es","private":false,"owner":{"login":"tangrams","id":8495302,"node_id":"MDEyOk9yZ2FuaXphdGlvbjg0OTUzMDI=","avatar_url":"https://avatars2.githubusercontent.com/u/8495302?v=4","gravatar_id":"","url":"https://api.github.com/users/tangrams","html_url":"https://github.com/tangrams","followers_url":"https://api.github.com/users/tangrams/followers","following_url":"https://api.github.com/users/tangrams/following{/other_user}","gists_url":"https://api.github.com/users/tangrams/gists{/gist_id}","starred_url":"https://api.github.com/users/tangrams/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tangrams/subscriptions","organizations_url":"https://api.github.com/users/tangrams/orgs","repos_url":"https://api.github.com/users/tangrams/repos","events_url":"https://api.github.com/users/tangrams/events{/privacy}","received_events_url":"https://api.github.com/users/tangrams/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/tangrams/tangram-es","description":"2D and 3D map renderer using OpenGL ES","fork":false,"url":"https://api.github.com/repos/tangrams/tangram-es","forks_url":"https://api.github.com/repos/tangrams/tangram-es/forks","keys_url":"https://api.github.com/repos/tangrams/tangram-es/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tangrams/tangram-es/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tangrams/tangram-es/teams","hooks_url":"https://api.github.com/repos/tangrams/tangram-es/hooks","issue_events_url":"https://api.github.com/repos/tangrams/tangram-es/issues/events{/number}","events_url":"https://api.github.com/repos/tangrams/tangram-es/events","assignees_url":"https://api.github.com/repos/tangrams/tangram-es/assignees{/user}","branches_url":"https://api.github.com/repos/tangrams/tangram-es/branches{/branch}","tags_url":"https://api.github.com/repos/tangrams/tangram-es/tags","blobs_url":"https://api.github.com/repos/tangrams/tangram-es/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tangrams/tangram-es/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tangrams/tangram-es/git/refs{/sha}","trees_url":"https://api.github.com/repos/tangrams/tangram-es/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tangrams/tangram-es/statuses/{sha}","languages_url":"https://api.github.com/repos/tangrams/tangram-es/languages","stargazers_url":"https://api.github.com/repos/tangrams/tangram-es/stargazers","contributors_url":"https://api.github.com/repos/tangrams/tangram-es/contributors","subscribers_url":"https://api.github.com/repos/tangrams/tangram-es/subscribers","subscription_url":"https://api.github.com/repos/tangrams/tangram-es/subscription","commits_url":"https://api.github.com/repos/tangrams/tangram-es/commits{/sha}","git_commits_url":"https://api.github.com/repos/tangrams/tangram-es/git/commits{/sha}","comments_url":"https://api.github.com/repos/tangrams/tangram-es/comments{/number}","issue_comment_url":"https://api.github.com/repos/tangrams/tangram-es/issues/comments{/number}","contents_url":"https://api.github.com/repos/tangrams/tangram-es/contents/{+path}","compare_url":"https://api.github.com/repos/tangrams/tangram-es/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tangrams/tangram-es/merges","archive_url":"https://api.github.com/repos/tangrams/tangram-es/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tangrams/tangram-es/downloads","issues_url":"https://api.github.com/repos/tangrams/tangram-es/issues{/number}","pulls_url":"https://api.github.com/repos/tangrams/tangram-es/pulls{/number}","milestones_url":"https://api.github.com/repos/tangrams/tangram-es/milestones{/number}","notifications_url":"https://api.github.com/repos/tangrams/tangram-es/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tangrams/tangram-es/labels{/name}","releases_url":"https://api.github.com/repos/tangrams/tangram-es/releases{/id}","deployments_url":"https://api.github.com/repos/tangrams/tangram-es/deployments","created_at":"2014-08-27T13:56:56Z","updated_at":"2018-09-23T18:28:07Z","pushed_at":"2018-09-22T13:58:15Z","git_url":"git://github.com/tangrams/tangram-es.git","ssh_url":"git@github.com:tangrams/tangram-es.git","clone_url":"https://github.com/tangrams/tangram-es.git","svn_url":"https://github.com/tangrams/tangram-es","homepage":"","size":36971,"stargazers_count":442,"watchers_count":442,"language":"C++","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":151,"mirror_url":null,"archived":false,"open_issues_count":138,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":151,"open_issues":138,"watchers":442,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/tangrams/tangram-es/pulls/1874"},"html":{"href":"https://github.com/tangrams/tangram-es/pull/1874"},"issue":{"href":"https://api.github.com/repos/tangrams/tangram-es/issues/1874"},"comments":{"href":"https://api.github.com/repos/tangrams/tangram-es/issues/1874/comments"},"review_comments":{"href":"https://api.github.com/repos/tangrams/tangram-es/pulls/1874/comments"},"review_comment":{"href":"https://api.github.com/repos/tangrams/tangram-es/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/tangrams/tangram-es/pulls/1874/commits"},"statuses":{"href":"https://api.github.com/repos/tangrams/tangram-es/statuses/553d8114150a0da86be02e8d89aa251a4e533e98"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"tallytalwar"}}