8000 Allow custom upload directories by kraftbj · Pull Request #70 · Automattic/wordbless · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Allow custom upload directories #70

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

Merged
merged 2 commits into from
Feb 12, 2025
Merged

Allow custom upload directories #70

merged 2 commits into from
Feb 12, 2025

Conversation

kraftbj
Copy link
Contributor
@kraftbj kraftbj commented Jan 31, 2025

We've created a setup in the Jetpack monorepo ( Automattic/jetpack#41057 ), that installs WorDBless once for a number of packages, then executes wordbless via a wrapper.

In individual, typical work, this works fine.

In our CI, we have the tests run concurrently, though, so we're hitting a situation where:

  • package 1 starts the unit testing and kicks off wordbless.
  • package 2 starts the unit testing and kicks off wordbless.
  • p2 uploads an image as part of a test.
  • p1 finishes, and calls wordbless' teardown which deletes the upload dir.
  • p2 runs a test expecting the upload present.
  • p2 fails.

For the moment, we're selectly installing wordbless via CI for those packages, but I'd like to update dbless to work as such:

  • p1 starts unit testing with a constant of dbless_UPLOADS=uploads-p1
  • p2 starts with dbless_UPLOADS=uploads-p2
  • p2 uploads.
  • p1 finishes, deletes uploads-p1
  • p2 tests work, since the image is in uploads-p2
  • p2 success, teardown will delete uploads-p2.

I believe this will do it, but will add a testing PR in Jetpack to consume this branch to confirm before merging.

@kraftbj kraftbj force-pushed the add/custom-upload-dir branch from ae32b82 to b116113 Compare January 31, 2025 17:26
@kraftbj kraftbj force-pushed the add/custom-upload-dir branch from 4d0e8d2 to e625279 Compare February 11, 2025 19:09
@kraftbj kraftbj marked this pull request as ready for review February 12, 2025 18:14
@kraftbj kraftbj merged commit f6a97b3 into trunk Feb 12, 2025
12 checks passed
@kraftbj kraftbj deleted the add/custom-upload-dir branch February 12, 2025 18:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0