Skip to content
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 unit tests for isBlockInSight() #13631

Merged
merged 1 commit into from Jun 26, 2023
Merged

Add unit tests for isBlockInSight() #13631

merged 1 commit into from Jun 26, 2023

Conversation

sfan5
Copy link
Member

@sfan5 sfan5 commented Jun 25, 2023

the bug did not reveal itself but we have a test now

To do

This PR is Ready for Review.

@sfan5 sfan5 added the Maintenance Tasks to keep the codebase and related parts in order, including architectural improvements label Jun 25, 2023
src/unittest/test_utilities.cpp Show resolved Hide resolved
src/unittest/test_utilities.cpp Outdated Show resolved Hide resolved
src/unittest/test_utilities.cpp Outdated Show resolved Hide resolved
src/unittest/test_utilities.cpp Outdated Show resolved Hide resolved
Copy link
Member

@SmallJoker SmallJoker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the changes. In the meantime I noticed that the map function does not actually shorten the code when compared to simple copying & iterating:

std::vector<v3s16> tmpdata = testdata1;
for (v3s16 &v : tmpdata)
	v.rotateXZBy(j*90);
test1(tmpdata);

Anyway, the expected return values do make sense and the code looks good 👍

@sfan5 sfan5 merged commit 442d5fc into minetest:master Jun 26, 2023
13 checks passed
@sfan5 sfan5 deleted the ibis branch June 26, 2023 20:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Maintenance Tasks to keep the codebase and related parts in order, including architectural improvements One approval ✅ ◻️
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants