Add TriggerTester methods to check that timers are set
- Dominant language
- Java
- Stars
- 8.7k
- Forks
- 4.7k
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 196
Description
TriggerTester exposes a `fireIfShouldFire(BoundedWIndow)` method. This is used to prompt a call to the trigger with the current state of the trigger tester (Input Watermarks, elements present, etc), and see if the trigger should fire. This is sufficient to test `shouldFire` of the `TriggerStateMachine` under test, but does not test that the `onElement` method sets an appropriate timer to cause such an interrogation to occur.
Imported from Jira [BEAM-694](https://issues.apache.org/jira/browse/BEAM-694). Original Jira may contain additional context.
Reported by: jkff.
Contributor guide
Research direction
Search the Apache Beam Java codebase for TriggerTester and its fireIfShouldFire(BoundedWindow) method, then read the surrounding TriggerStateMachine test helpers. Trace how onElement currently handles trigger state and timers, and identify the existing timer-related test entry points. Done means TriggerTester can verify that onElement sets the appropriate timer, with coverage for that behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- stream-processing
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100