-
-
Notifications
You must be signed in to change notification settings - Fork 21.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add extra unit tests for Transform2D
#74999
Conversation
The failed tests seem to be related to the unit test of looking_at failing, which I've addressed. Do all tests need to pass for review? |
All tests have to pass for merger, probably can't be reviewed until a fix for that bug is added and the test passes for it |
I've rewritten the looking_at function. I'm not too familiar with the procedures here. Should I open a new pull request for changing looking_at, since it makes sense to have 2 seperate pull requests when I'm appending code in one area of the code base and changing another area of the code. However, it seems like I can only make one pull request for my fork. |
You can only make one PR per branch, you should make any contributions on individual branches to make this easier |
Okay I have reverted the change to looking_at here and made a new PR that specifically changes the function. |
I would recommend moving the |
Transform2D
CHECK(test == expected); | ||
} | ||
|
||
TEST_CASE("[transform2d] Constructor from angle, scale, skew and position") { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TEST_CASE("[transform2d] Constructor from angle, scale, skew and position") { | |
TEST_CASE("[Transform2d] Constructor from angle, scale, skew and position") { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TEST_CASE("[transform2d] Constructor from angle, scale, skew and position") { | |
TEST_CASE("[Transform2D] Constructor from angle, scale, skew and position") { |
} | ||
|
||
TEST_CASE("[transform2d] Constructor from angle, scale, skew and position") { | ||
const float ROTATATION = Math_PI / 2; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const float ROTATATION = Math_PI / 2; | |
const float ROTATION = Math_PI / 2; |
and likewise where it's used.
} | ||
|
||
TEST_CASE("[Transform2D] Constructor from angle and position") { | ||
const float ROTATATION = Math_PI / 4; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const float ROTATATION = Math_PI / 4; | |
const float ROTATION = Math_PI / 4; |
And where used
Superseded by #90506. Thanks for the contribution! |
Added extra tests to cover almost all functions in the Transform2D class. Note that the looking_at tests fail with the current implementation of the function. Issue raised in #74966.
Sorry for duplicate #74977. I deleted my repo on accident.