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

Files used in unit tests remain in /tmp #4048

Closed
abetomo opened this issue Feb 9, 2023 · 3 comments · Fixed by #4050
Closed

Files used in unit tests remain in /tmp #4048

abetomo opened this issue Feb 9, 2023 · 3 comments · Fixed by #4050
Assignees

Comments

@abetomo
Copy link
Contributor

abetomo commented Feb 9, 2023

Describe the bug

After rake test, the following files remained in /tmp.

  • /tmp/SERVERENGINE_SOCKETMANAGER_*
  • /tmp/fluentd-lock-*
  • /tmp/fluent/

To Reproduce

  1. rake test
  2. ls /tmp

Expected behavior

Files created by tests should be deleted.

Your Environment

- Fluentd version: 1.15.3
- Operating system: Ubuntu 22.04
- Kernel version: 5.15.0-58-generic

Your Configuration

-

Your Error Log

-

Additional context

No response

@daipom daipom self-assigned this Feb 10, 2023
@daipom
Copy link
Contributor

daipom commented Feb 10, 2023

Thanks for your report!

I ran a few tests first, but no temporary files were left.

$ bundle exec rake test TESTOPTS="-t'SupervisorTest'"
$ bundle exec rake test TESTOPTS="-t'FileOutputTest'"

Some specific tests may be the cause.
I am concerned that it may be difficult to identify which test is the cause...

I am running all tests in my local environment now.

@abetomo
Copy link
Contributor Author

abetomo commented Feb 10, 2023

I have been able to identify a few causes.

#4050
This fix removes several files.

@daipom
Copy link
Contributor

daipom commented Feb 10, 2023

Wow! Thanks!

I can confirm those files are left in /tmp/ after running all tests.

We might also consider the idea that since it is in /tmp/, it is not a problem if it remains to some extent.

If there is a test where we obviously forget something, it would be nice to fix it.

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

Successfully merging a pull request may close this issue.

2 participants