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

new feature: improve the test cleanup to remove all test files after running tests #5143

Open
1 task
meteorgan opened this issue Sep 25, 2024 · 0 comments
Open
1 task
Labels
enhancement New feature or request

Comments

@meteorgan
Copy link
Contributor

meteorgan commented Sep 25, 2024

Feature Description

delete all test files permanently after running tests

Problem and Solution

Current behaviors

  1. some test files are generated by TEST_FIXTURE, they gets deleted automatically after running the tests. such as:
    let (path, content, size) = TEST_FIXTURE.new_file(op.clone());
  2. some test files are generated during test cases and are manually removed before the test cases finish. such as:
    let path = uuid::Uuid::new_v4().to_string();

Problems

There are some cases where the test files might not be permanently deleted, which could lead to increased storage usage in backend services.

  1. In the first scenario, when versioning is enabled, even if we delete the test files after running the tests, they still remain due to versioning. To remove them permanently, we must use a delete operation that specifies the version.
  2. In the second scenario, if the test cases fail, the cleanup process will not be executed, leaving the test files behind.

Additional Context

No response

Are you willing to contribute to the development of this feature?

  • Yes, I am willing to contribute to the development of this feature.
@meteorgan meteorgan added the enhancement New feature or request label Sep 25, 2024
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

No branches or pull requests

1 participant