-
Notifications
You must be signed in to change notification settings - Fork 115
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
Refactor integration tests #1299
Refactor integration tests #1299
Conversation
80f98fa
to
f73bf7f
Compare
Please fix the lint warnings before merging. |
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.
Can you please add a comment early in this file that explains how these tests are "old" (ie. they are still valid and up-to-date, but need to be converted to the new testing approach).
} from '@temporalio/worker'; | ||
import * as workflow from '@temporalio/workflow'; | ||
import { ConnectionInjectorInterceptor } from '../activities/interceptors'; | ||
import { Worker, test as anyTest, bundlerOptions } from '../helpers'; |
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.
Would it be difficult/disruptive to merge the content of this file into ../helpers.ts
?
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.
That sounds good, I'm happy for any further renaming/reorganizing tweaks to be done here; I just wanted to start getting things in shape while adding new tests for Update.
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.
I'm just a bit uncomfortable with file names (-old
and helpers
). I gave some details inline.
Not blocking however. Feel free to merge as is if you prefer. These can be addressed at a later point.
Thanks for reviewing. The file name in this PR I am most uncomfortable with is |
There was a mistake in temporalio#1299: tests inside the `integration-tests` subdirectory were not being run. But that mistake emphasizes that it's not really desirable to have the nested directory. So instead of modifying the `test` and `test.watch` command definitions in `package.json`, this PR flattens the directory structure as follows ``` helpers.ts helpers-integration.ts // helper boilerplate shared by the new-style integration tests test-integration-*.ts // i.e. new style integration tests (i.e. not matching -old-*.ts) test-integration-old-*.ts // old-style integration tests ```
This is pure refactoring of the integration tests, done in preparation for implementation of Workflow Update in #1277.