-
Notifications
You must be signed in to change notification settings - Fork 214
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow setting activity timeouts in testsuite #1187
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -262,6 +262,16 @@ func (t *TestActivityEnvironment) SetOnActivityHeartbeatListener( | |
return t | ||
} | ||
|
||
// SetActivityStartToCloseTimeout sets the start to close timeouts of activities in the test environment. | ||
func (e *TestActivityEnvironment) SetActivityStartToCloseTimeout(timeout time.Duration) { | ||
e.impl.testWorkflowEnvironmentShared.activityStartToCloseTimeout = timeout | ||
} | ||
|
||
// SetActivityStartToCloseTimeout sets the schedule to close timeouts of activities in the test environment | ||
func (e *TestActivityEnvironment) SetActivityScheduleToCloseTimeout(timeout time.Duration) { | ||
e.impl.testWorkflowEnvironmentShared.activityScheduleToCloseTimeout = timeout | ||
} | ||
Comment on lines
+265
to
+273
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Hrmm, longer than 10-minutes using this framework is a bit rough. You might consider a proper integration test with a real server instead. Regardless, I wonder if we should document on these what the default is and document any relation to There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah we should include a comment here on what the default values are |
||
|
||
// RegisterWorkflow registers workflow implementation with the TestWorkflowEnvironment | ||
func (e *TestWorkflowEnvironment) RegisterWorkflow(w interface{}) { | ||
e.impl.RegisterWorkflow(w) | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The low timing resolution/granularity of this test will lead to flakiness on an overloaded CI worker. I think you can just remove the no-timeout assertion part.