Repository navigation
Tests: haptics, the idle screen, the hit shake and the bonus flash - #42
Merged
Merged
Conversation
Fourteen Google Test cases on behaviour the suite had not pinned down: - Haptics: a bomb hit fires the haptic callback once, the last life and the invasion still do, a shielded hit and a power-up pickup do not. - Idle screen: only the title, game over and win screens are idle (a round and the level-clear animation are not); the phone idles while the glasses play the round, the glasses instance itself does not. - Effects: a hit shakes the screen at full strength and the shake settles within a second; a shielded hit shakes at half strength; a new level starts still; a caught power-up flashes its level-scaled value just above where it was caught and fades; a new game clears the flash. - Tally: a new game resets level, lives, score, the shot counters, the power-ups, the high-score flag and the battlefield. game.h gains debug-only accessors for the lives, the shake amount and the bonus flash. README test count 128 -> 142.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fourteen Google Test cases on behaviour the suite had not pinned down.
game.hgains debug-only accessors for the lives, the shake amount and the bonus flash. README test count 128 -> 142.Verified:
scripts/host-tests.sh142/142; the Debug native build (NDK clang,game_testsfor both ABIs) compiles.