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

Fix healthy, NPC attack tests #49828

Merged
merged 2 commits into from
Jul 11, 2021

Conversation

anothersimulacrum
Copy link
Member

Summary

None

Purpose of change

Make tests pass.

Describe the solution

The healthy tests likely stopped working due to the change in healthy rounding, adjust them to pass.

In the NPC attack tests:

Move the player so game::load_npcs will actually spawn the NPCs.
Add REQUIREs to make the game not crash on failing to spawn NPCs.
Remove the weather setting because it doesn't change the tests, and causes vision tests failures due to side effects!
Adjust the values of the m16a4 test to start passing.

Describe alternatives you've considered

Tracking down the weather stuff more.

Testing

tests/cata_test

@anothersimulacrum anothersimulacrum added <Bugfix> This is a fix for a bug (or closes open issue) [C++] Changes (can be) made in C++. Previously named `Code` Code: Tests Measurement, self-control, statistics, balancing. labels Jul 10, 2021
These likely stopped working due to the changes in healthy rounding.
Move the player so game::load_npcs will actually spawn the NPCs.

Add REQUIREs to make the game not crash on failing to spawn NPCs.

Remove the weather setting because it doesn't change the tests, and
causes vision tests failures due to side effects!

Adjust the values of the m16a4 test to start passing.
@kevingranade kevingranade merged commit 300f975 into CleverRaven:master Jul 11, 2021
@anothersimulacrum anothersimulacrum deleted the tests-fixes branch July 11, 2021 05:18
BrettDong added a commit that referenced this pull request Nov 27, 2021
ZhilkinSerg pushed a commit that referenced this pull request Nov 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
<Bugfix> This is a fix for a bug (or closes open issue) [C++] Changes (can be) made in C++. Previously named `Code` Code: Tests Measurement, self-control, statistics, balancing.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants