Repository navigation
Testing and Reviews
How PF1e Revamp is checked before each release.
PF1e Revamp is written by Claude, Anthropic's AI, working in Claude Code. Claude writes the code, tests and documentation, and runs all the testing described below in a live Foundry world. The project lead, mr-nobody20777, decides what gets built and how it should play at the table, sets the design rules, and reviews the results. Every commit is co-authored by Claude.
Every automation starts from the full rules text of the ability, feat, trait or spell, and the rule is quoted at the top of the code that implements it. When PF1's or Pathfinder 1e Content's data disagrees with the rules, the rules win and the item's note says so. Examples: the auras' always-on bonuses, and Magical Knack's missing Hit Dice cap.
The module includes a test suite of over 520 tests in 51 groups, run with the Quench module. Each group:
- creates throwaway characters, tokens and combats on a dedicated test scene;
- uses features through PF1's real actions and rolls, the same way a player would;
- checks the results on the chat cards and character sheets;
- deletes everything it created.
New features ship with their tests, and the whole suite runs before every release.
To run it yourself: install and enable Quench, open it from the sidebar, select the PF1e Revamp groups and click Run. Use a test world, since tests briefly create and delete characters, tokens and chat messages.
Most automated tests run as a GM, and a GM can change anything, so permission problems would never show up there. Before release, every feature that touches another character was also played through logged in as a regular player, with a separate GM connected. That covered buffs on allies, channel energy, spontaneous casting, Prescience, Rewind, Forewarned, raging songs, Studied Target, miss chances, sneak attack talents, and spells cast by and at a player (saves rolled from the card, templates placed on the map). For 0.21.0: auras started from a player's Use button and ended from their buff, and damage a player applies to a creature they don't control. For the spells release: a player's summons, a player deleting their own lasting area (the GM's game releases the creatures inside), a polymorph cast with an enemy targeted, and metamagic cast through Nevela's Automation Suite. All worked. See Compatibility for how the GM's client handles those changes.
Before release, the new code gets a review for bugs, and the features are tried on monsters straight from the Bestiary (unlinked tokens, real damage reduction and Hit Dice) and in a full combat with the test party: auras turned on and walked in and out of, damage applied from the card against DR and resistances, regeneration stopped by fire, and buffs running out on their owner's turn. For 0.21.0 this found and fixed twelve problems before release. For the spells release (summons, metamagic, polymorph, lasting areas and every spell of the other books), two review passes found and fixed nineteen problems, among them a summon misplaced behind a wall that a player couldn't remove, a second Acid Arrow replacing the first one's rounds, Elemental Spell changing a spell for good, and a player's deleted area leaving its conditions in place.
After every ten new features, the code gets a review aimed at keeping games running smoothly, without the slowdowns that make people refresh Foundry mid-session:
- removing duplicated code and unused work;
- checking for memory leaks: listeners added repeatedly, caches that grow forever;
- keeping the busiest moments light: chat messages being rendered, characters being recalculated, dice being rolled.
Each review is measured with a benchmark (module/tests/benchmark.mjs). It simulates a busy session (hundreds of character recalculations and chat renders, dozens of attacks, saves, skill checks and buff toggles) and times every one of the module's handlers:
| Review | The module's share of the session |
|---|---|
| #1 | 0.53% → 0.17% |
| #2 | 0.29% → 0.20% (after ten more features) |
| #3 | 0.23% → 0.22% (after ten more features, including the roll windows' buff manager) |
| #4 | 2.85% → 0.50% (a fuller workload: magic arms, every hook found by its source) |
| #5 | 0.75% → 0.60% (afflictions, lasting areas, token moves and game-time ticks added) |
| #6 | 0.97% → 1.0% (combat turns with a summoned creature and spell casts added; summon lookups indexed, so turns no longer scan every actor and token in large worlds) |
Every handler costs well under a millisecond per call, and memory showed no lasting growth. A full combat turn costs the module about 2.6 ms.
- Your existing items. Automation recognizes PF1's and Pathfinder 1e Content's own items in place, by compendium source, tag or name, so there's nothing to swap in or keep in sync.
- State on items. Ongoing effects live on items and buffs, so they survive a page refresh and show on the sheet.
- Derived bonuses. Granted traits like energy resistance are added while PF1 calculates the character, never written into the character's data. Removing the source removes the effect.
- Undo. Archetypes, racial traits and subclass powers record exactly what they changed on their own item and restore it when removed.
-
Hooks. The module hooks into PF1 through its documented hooks (
pf1PreAttackRoll,pf1PreActorRollSave,pf1PostActionUseand others). The few places it wraps PF1's code go through libWrapper, registered once per method and shared by all features.
Character options
Play
Reference