GitHub PullRequestReviewCommentEvent at 2014-03-18 12:31:20
Repository: ogs
Actor: norihiro-w
Payload: {"comment":{"url":"https://api.github.com/repos/ufz/ogs/pulls/comments/10700200","id":10700200,"diff_hunk":"@@ -72,5 +73,42 @@\n \tASSERT_EQ(offset_zn1+offset_yn0+n_subdivisions, ele_n.getNodeIndex(5));\n \tASSERT_EQ(offset_zn1+offset_yn1+n_subdivisions, ele_n.getNodeIndex(6));\n \tASSERT_EQ(offset_zn1+offset_yn1+n_subdivisions-1, ele_n.getNodeIndex(7));\n+\n+\tstd::unique_ptr<Mesh> msh2 (MeshGenerator::generateRegularHexMesh(n_subdivisions, n_subdivisions, n_subdivisions, L/n_subdivisions));\n+\tASSERT_EQ(msh->getNNodes(), msh2->getNNodes());\n+\tASSERT_EQ(0, MathLib::sqrDist(*(msh->getNode(msh->getNNodes()-1)), *(msh2->getNode(msh->getNNodes()-1))));\n+\n+\tunsigned n_x (10);\n+\tunsigned n_y (5);\n+\tunsigned n_z (2);\n+\tdouble delta (1.2);\n+\tstd::unique_ptr<Mesh> hex_mesh (MeshGenerator::generateRegularHexMesh(n_x, n_y, n_z, delta));\n+\tASSERT_EQ(n_x * n_y * n_z, hex_mesh->getNElements());\n+\tASSERT_EQ((n_x+1) * (n_y+1) * (n_z+1), hex_mesh->getNNodes());\n+\tconst MeshLib::Node* node (hex_mesh->getNode(hex_mesh->getNNodes()-1));\n+\tASSERT_EQ(n_x*delta, (*node)[0]);","path":"Tests/MeshLib/TestMeshGenerator.cpp","position":25,"original_position":25,"commit_id":"3c4a20b57a80894da4842501a18659c16b4d5c5e","original_commit_id":"3c4a20b57a80894da4842501a18659c16b4d5c5e","user":{"login":"norihiro-w","id":800408,"avatar_url":"https://avatars.githubusercontent.com/u/800408?","gravatar_id":"48dbb4167ba59bcbbc83427b10449404","url":"https://api.github.com/users/norihiro-w","html_url":"https://github.com/norihiro-w","followers_url":"https://api.github.com/users/norihiro-w/followers","following_url":"https://api.github.com/users/norihiro-w/following{/other_user}","gists_url":"https://api.github.com/users/norihiro-w/gists{/gist_id}","starred_url":"https://api.github.com/users/norihiro-w/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/norihiro-w/subscriptions","organizations_url":"https://api.github.com/users/norihiro-w/orgs","repos_url":"https://api.github.com/users/norihiro-w/repos","events_url":"https://api.github.com/users/norihiro-w/events{/privacy}","received_events_url":"https://api.github.com/users/norihiro-w/received_events","type":"User","site_admin":false},"body":"why not use ASSERT_DOUBLE_EQ or ASSERT_NEAR?","created_at":"2014-03-18T12:31:20Z","updated_at":"2014-03-18T12:31:20Z","html_url":"https://github.com/ufz/ogs/pull/367#discussion_r10700200","pull_request_url":"https://api.github.com/repos/ufz/ogs/pulls/367","_links":{"self":{"href":"https://api.github.com/repos/ufz/ogs/pulls/comments/10700200"},"html":{"href":"https://github.com/ufz/ogs/pull/367#discussion_r10700200"},"pull_request":{"href":"https://api.github.com/repos/ufz/ogs/pulls/367"}}}}