Commit Graph

19 Commits

Author SHA1 Message Date
Taylor Mullen f54fe58d06 test: fix windows environment and cleanup issues
- Ensure 'SystemRoot', 'COMSPEC', 'windir', and 'PATHEXT' are passed to node-pty on Windows to prevent 'posix_spawnp' failures.
- Clean up test directories in 'TestRig.setup' to ensure a fresh state for retries and prevent telemetry log accumulation (fixing the 1, 2, 3 failure pattern).
- Fix path normalization in 'Hook Disabling' test to ensure disabled hooks are correctly matched on Windows.

Part of https://github.com/google-gemini/gemini-cli/pull/18665
2026-02-13 16:03:09 -08:00
Taylor Mullen bd7904a9f7 test: robust fixes for windows hook flakiness
- Enforce 'sequential: true' for all hook tests to prevent telemetry leaks and race conditions.
- Normalize all path assertions in hooks-system.test.ts using a new 'normalizePath' helper to handle Windows backslashes consistently.
- Update 'createScript' in test-rig to return normalized paths.
- Ensure 'PATH' is explicitly passed to node-pty spawn options to prevent 'posix_spawnp' errors in some environments.
- Clean up manual path replacements in tests in favor of the centralized helper.

Part of https://github.com/google-gemini/gemini-cli/pull/18665
2026-02-13 16:03:09 -08:00
Taylor Mullen 519bf324b0 test: standardize hook system tests for windows compatibility
- Refactored remaining hook tests in hooks-system.test.ts to use 'rig.createScript' and forward slashes for cross-platform path compatibility.
- Replaced 'node -e' usages with script files to avoid brittle quoting and escaping issues on Windows shells.

Part of https://github.com/google-gemini/gemini-cli/pull/18665
2026-02-13 16:03:09 -08:00
Taylor Mullen 9631dc8abf test: fix hook integration test flakiness on Windows CI
- Increase default timeout for TestRig.run and TestRig.runCommand to 10 minutes on Windows CI to handle slow environments.
- Replace inline 'node -e' hook commands with script files to avoid brittle quoting and escaping issues on Windows shells.
- Add 'TestRig.createScript' helper to simplify script creation in tests.
- Fix path escaping for hook output files in 'hooks-agent-flow.test.ts' using JSON.stringify.
- Ensure 'TestRig.setup' is called before performing file operations in tests.
2026-02-13 16:03:08 -08:00
jw bot 0a77999d73 test(core): mock fetch in OAuth transport fallback tests (#17059)
Co-authored-by: Bryan Morgan <bryanmorgan@google.com>
2026-01-28 13:30:08 +00:00
Jerop Kipruto c21c297133 feat(plan): refactor TestRig and eval helper to support configurable approval modes (#17171) 2026-01-21 15:43:48 +00:00
joshualitt 211d2c5fdd feat(core): Ensure all properties in hooks object are event names. (#16870) 2026-01-20 22:47:31 +00:00
Christian Gunderman 88df6210eb Test coverage for hook exit code cases (#17041) 2026-01-20 17:13:15 +00:00
joshualitt 56092bd782 feat(hooks): Add a hooks.enabled setting. (#15933) 2026-01-06 21:33:37 +00:00
Tommaso Sciortino 8f0324d868 fix(cli): resolve paste issue on Windows terminals. (#15932) 2026-01-05 22:46:23 +00:00
Christian Gunderman 6d1e27633a Support context injection via SessionStart hook. (#15746) 2026-01-05 21:27:53 +00:00
Sandy Tao 05049b5abf feat(hooks): implement STOP_EXECUTION and enhance hook decision handling (#15685) 2025-12-30 23:22:53 +00:00
Christian Gunderman 90eb1e0281 Implement support for tool input modification (#15492) 2025-12-30 19:37:43 +00:00
Abhi 15c9f88da6 fix(hooks): deduplicate agent hooks and add cross-platform integration tests (#15701) 2025-12-30 19:13:16 +00:00
Tommaso Sciortino bb0c0d8ee3 Simplify method signature. (#15114) 2025-12-15 21:18:04 +00:00
Edilmo Palencia b8c038f41f feat(hooks): Hooks Commands Panel, Enable/Disable, and Migrate (#14225) 2025-12-03 18:01:57 +00:00
Edilmo Palencia 1c12da1fad feat(hooks): Hook Session Lifecycle & Compression Integration (#14151) 2025-12-03 17:04:13 +00:00
Jack Wotherspoon 576fda18eb chore: fix session browser test and skip hook system tests (#14099) 2025-11-28 21:07:54 +00:00
Edilmo Palencia 7a4280a482 feat(hooks): Hooks Comprehensive Integration Testing (#9112) 2025-11-27 05:38:35 +00:00