pokerogue/test
Sirz Benjie e5e0835a96
[Misc][Refactor] Add scaffolding for TypedArrays and improve typing on methods related to arrays (#6547)
* make IVs use Uint8Array

* Add many typed array helpers

* Move array utils to its own file

* Add suppression comment

* Adjust type of `getStats`

* Adjust test mocks to use typed arrays

* Adjust signatures of some phases to use ArrayLike<T>

* Adjust signature of src/ui/containers/stats-container#updateIvs

* Remove comment gap to try to satisfy typedoc

* Ensure ivs are always set

* fix: fun-and-games me to use typed array

* Add new tests for array utilities

* Update type of ivs in save-data.ts

* Update part-timer-encounter.test.ts

* Convert uses of StatusEffect[] to Uint8Array

* Update ssui to use uint8array for ivs

* Revert use of typed arrays

* Move `nil` to @types/common

* Make more arrays readonly

* fix: remnant change to immune effects

* Even more array improvements

* Apply kev's suggestions from code review

Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>

* address Bertie's comments from code review

* tests: remove undefined check for bigint array types

* fixup abilities.ts

---------

Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>
2025-10-06 12:21:58 -05:00
..
@types [Test] Added Map key matcher; enforced strong typing on matchers (#6561) 2025-09-20 17:24:27 -05:00
abilities fix: camel case liquid ooze 2025-10-06 11:36:46 -05:00
achievements [Misc] [UX] Add Daily Run Achievement, Re-Arrange Achievements, Replace some Icon Sprites (#6292) 2025-08-22 19:21:17 -04:00
ai [Balance] Adjust evolution delay requirements (#6595) 2025-09-30 12:59:08 -05:00
arena [Test] Replace game.scene.getXPokemon()! with game.field.getXPokemon() 2025-08-04 21:19:57 -07:00
battle [Misc/Feature] Add dynamic turn order (#6036) 2025-09-20 17:49:40 -05:00
battler-tags [Bug] [Refactor] [Move] Add selection prevention and move failures (#6276) 2025-09-29 12:08:42 -05:00
challenges [Bug] [Refactor] [Move] Add selection prevention and move failures (#6276) 2025-09-29 12:08:42 -05:00
data [Dev] Improve typescript performance and version bump node and dependencies (#6627) 2025-10-04 19:29:23 -05:00
eggs [Refactor] Remove isNullOrUndefined in favor of loose check against null (#6549) 2025-09-12 14:53:27 -05:00
field [Balance] Enemy trainer Pokemon will have friendship based on the wave 2025-10-03 12:09:35 -04:00
inputs [Misc] Standardize-file-names (#6137) 2025-07-24 16:38:31 -04:00
items [Test] Updated more uses of game.scene.getEnemyField and game.scene.getPlayerField to use updated test utils (#6524) 2025-09-18 09:36:08 -05:00
moves [Misc][Refactor] Add scaffolding for TypedArrays and improve typing on methods related to arrays (#6547) 2025-10-06 12:21:58 -05:00
mystery-encounter [Balance] Adjust evolution delay requirements (#6595) 2025-09-30 12:59:08 -05:00
phases [Misc] Simplifying imports of UI files (#6542) 2025-09-11 00:30:17 -07:00
plugins/api [Misc][UI/UX] See stats of other users in admin panel (#6579) 2025-09-27 14:44:29 -07:00
setting-menu [Dev] Migrated to Biome 2.2.3, added more rules (#6259) 2025-09-08 10:35:18 -05:00
setup [Refactor][Dev] Move public to its own submodule (#6590) 2025-09-27 11:01:12 -05:00
sprites [Refactor][Dev] Move public to its own submodule (#6590) 2025-09-27 11:01:12 -05:00
status-effects [Bug] Fix status effects overwriting each other (#6392) 2025-08-24 12:51:16 -05:00
system [Refactor] Move type definitions away from game-data.ts (#6487) 2025-09-10 14:09:33 -05:00
test-utils [Misc][Refactor] Add scaffolding for TypedArrays and improve typing on methods related to arrays (#6547) 2025-10-06 12:21:58 -05:00
types [Test] Port over + augment remaining test matchers from pkty (#6159) 2025-08-02 15:35:06 -07:00
ui [Bug] [Refactor] [Move] Add selection prevention and move failures (#6276) 2025-09-29 12:08:42 -05:00
utils [Misc][Refactor] Add scaffolding for TypedArrays and improve typing on methods related to arrays (#6547) 2025-10-06 12:21:58 -05:00
account.test.ts [Dev] Enable Biome import sorting (#6052) 2025-07-13 00:21:25 -07:00
battle-scene.test.ts [Misc] Standardize-file-names (#6137) 2025-07-24 16:38:31 -04:00
boss-pokemon.test.ts [Refactor] Refactor boss health segment calculation to improve clarity (#6574) 2025-09-22 20:08:39 -05:00
daily-mode.test.ts [Misc] Simplifying imports of UI files (#6542) 2025-09-11 00:30:17 -07:00
endless-boss.test.ts [Test] Replace game.scene.getXPokemon()! with game.field.getXPokemon() 2025-08-04 21:19:57 -07:00
enemy-command.test.ts [Test] Replace game.scene.getXPokemon()! with game.field.getXPokemon() 2025-08-04 21:19:57 -07:00
escape-calculations.test.ts [Test] Updated more uses of game.scene.getEnemyField and game.scene.getPlayerField to use updated test utils (#6524) 2025-09-18 09:36:08 -05:00
evolution.test.ts [Balance] Adjust evolution delay requirements (#6595) 2025-09-30 12:59:08 -05:00
final-boss.test.ts [Test] Replace game.scene.getXPokemon()! with game.field.getXPokemon() 2025-08-04 21:19:57 -07:00
game-mode.test.ts [Misc] Standardize-file-names (#6137) 2025-07-24 16:38:31 -04:00
internals.test.ts [Test] Replace game.scene.getXPokemon()! with game.field.getXPokemon() 2025-08-04 21:19:57 -07:00
misc.test.ts [Misc] Move asset initialization from preload to launchBattle 2025-08-02 14:29:35 -07:00
reload.test.ts [Misc] Standardize-file-names (#6137) 2025-07-24 16:38:31 -04:00
utils.test.ts [Dev] Enable Biome import sorting (#6052) 2025-07-13 00:21:25 -07:00