pokerogue/test/testUtils
Sirz Benjie 389ad6ceb6
[Tests][UI/UX] Add automated tests for the pokedex (#5637)
* Remove unneeded fields from src/ui/filter-text.ts

* Add setOverlayMode to phaseInterceptor

* initialize pokemon starters before running tests

* Add getWrappedText to mockText

* Add initial pokedex test

* Add test for wrapping cursor in pokedex view

* Make pokedex use getPassiveAbility instead of checking passive map

Allows for tests to mock passives

* Add test for filtering double ability combinations

* Add test for filtering by types

* Mark failing test as TODO

* Apply suggestions from code review

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

* Use ts-expect-error instead of ts-ignore in comments

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

* Add save for pokedex tests

* Add test for filtering by cost reduction

* Add test for filtering by shiny

* Add tests for filtering by cost reductions

* Fix typo in test name

* Update test/ui/pokedex.test.ts

Co-authored-by: Wlowscha <54003515+Wlowscha@users.noreply.github.com>

* Update Mode import in pokedex test

* Replace reference to Mode with UiMode

---------

Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>
Co-authored-by: Madmadness65 <59298170+Madmadness65@users.noreply.github.com>
Co-authored-by: Wlowscha <54003515+Wlowscha@users.noreply.github.com>
2025-04-23 18:10:01 +00:00
..
helpers [Refactor][Move] Refactor move effect phase (#5678) 2025-04-23 00:10:27 +00:00
mocks [Tests][UI/UX] Add automated tests for the pokedex (#5637) 2025-04-23 18:10:01 +00:00
saves [Tests][UI/UX] Add automated tests for the pokedex (#5637) 2025-04-23 18:10:01 +00:00
errorInterceptor.ts [Misc][Refactor][GitHub] Ditch eslint for biome, and add a formatter (#5495) 2025-03-09 14:13:25 -07:00
fakeMobile.html [Test] Move test folder out of src (#5398) 2025-02-22 22:52:07 -06:00
gameManager.ts [Refactor] Remove circular imports part 1 (#5663) 2025-04-19 11:57:03 +00:00
gameManagerUtils.ts [Bug] Fix forced switch bugs in enemy partner trainer battles (#5644) 2025-04-18 09:35:46 +00:00
gameWrapper.ts [Tests][UI/UX] Add automated tests for the pokedex (#5637) 2025-04-23 18:10:01 +00:00
inputsHandler.ts [Misc][Refactor][GitHub] Ditch eslint for biome, and add a formatter (#5495) 2025-03-09 14:13:25 -07:00
listenersManager.ts [Test] [Refactor] [GitHub] Enable no isolate for vitest (#5566) 2025-03-28 17:30:38 -04:00
phaseInterceptor.ts [Tests][UI/UX] Add automated tests for the pokedex (#5637) 2025-04-23 18:10:01 +00:00
testFileInitialization.ts [Tests][UI/UX] Add automated tests for the pokedex (#5637) 2025-04-23 18:10:01 +00:00
testUtils.ts [Test] Move test folder out of src (#5398) 2025-02-22 22:52:07 -06:00
TextInterceptor.ts [Misc][Refactor][GitHub] Ditch eslint for biome, and add a formatter (#5495) 2025-03-09 14:13:25 -07:00