Skip to content
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 TestActivityEnvironment #1167

Open
ohad83 opened this issue Jul 19, 2023 · 4 comments · May be fixed by #1187
Open

Allow setting activity timeouts in TestActivityEnvironment #1167

ohad83 opened this issue Jul 19, 2023 · 4 comments · May be fixed by #1187
Labels
enhancement New feature or request

Comments

@ohad83
Copy link

ohad83 commented Jul 19, 2023

Currently, the TestActivityEnvironment has a hard-coded 10 minute timeout. If I want to use the test suite to run an activity which takes longer than that, it fails with a timeout error.

Adding the ability to run the activity with options like timeout values in the test environment would help a lot in testing and debugging long activities.

Thanks!

@ohad83 ohad83 added the enhancement New feature or request label Jul 19, 2023
@Delicious-Bacon
Copy link

+1 to this.

Activity test times out at 10 minute point, which is too short for some of my activities.

@ohad83 ohad83 linked a pull request Aug 5, 2023 that will close this issue
@cretz
Copy link
Member

cretz commented Aug 7, 2023

If I want to use the test suite to run an activity which takes longer than that, it fails with a timeout error.

While supporting an override is fine, in general I think you should use a real server if you are running such tests (you can easily start a dev server using the testsuite package).

@Delicious-Bacon
Copy link

you can easily start a dev server using the testsuite package

Which is extra boilerplate code just to execute an Activity, isn't it?

I already have loads of test Workflows that bloat my project and bring confusion by decoupling the Go's testing tools from those "tests". I end up saving results of those Workflows to a file and then manually check the results instead of implementing testing package.

@cretz
Copy link
Member

cretz commented Oct 9, 2023

Which is extra boilerplate code just to execute an Activity, isn't it?

Not sure about "boilerplate". It starts a real server you can do real integration tests on. There's a lot of value in running against a real server.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants