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

Make python tests not executables #5449

Merged
merged 3 commits into from
Oct 30, 2017

Conversation

tsg
Copy link
Contributor

@tsg tsg commented Oct 26, 2017

Turns out that if a test_*.py file is executable, nosetests
doesn't pick it up, so the tests are not executed on Linux/Mac.
This was the case with two files in Filebeat.

This adds a make check check to look for such files, so this
doesn't happen in the future.

Turns out that if a `test_*.py` file is executable, nosetests
doesn't pick it up, so the tests are not executed on Linux/Mac.
This was the case with two files in Filebeat.

This adds a `make check` check to look for such files, so this
doesn't happen in the future.
@tsg tsg added needs_backport PR is waiting to be backported to other branches. review labels Oct 26, 2017
@tsg
Copy link
Contributor Author

tsg commented Oct 26, 2017

I opened this separately from #5443 so we can backport it immediately to the 6.0 branch.

@tsg tsg added the :Testing label Oct 26, 2017
@andrewkroh
Copy link
Member

find: invalid mode ‘+111’ coming from Jenkins

@andrewkroh
Copy link
Member

andrewkroh commented Oct 26, 2017

man find (on Linux)

-perm +mode
This is no longer supported (and has been deprecated since 2005). Use -perm /mode instead.

These work on Linux but not on macOS. hmm

-perm /a+x
-type f -executable

@andrewkroh
Copy link
Member

andrewkroh commented Oct 27, 2017

test_prospector.Test.test_harvester_limit is failing on Travis for both Linux and macOS, but it's passing on Jenkins. 😕

@tsg
Copy link
Contributor Author

tsg commented Oct 27, 2017

That test seems stable on my computer, so I'm pretty clueless on why it might fail on Travis only.

@tsg
Copy link
Contributor Author

tsg commented Oct 27, 2017

No, I spoke to soon. The test is flaky and I could get it to fail on my laptop when running it in a loop.

@tsg
Copy link
Contributor Author

tsg commented Oct 27, 2017

I opened #5458 for the flaky test.

@tsg
Copy link
Contributor Author

tsg commented Oct 27, 2017

I skipped the flaky test, we have #5458 to track that.

@tsg
Copy link
Contributor Author

tsg commented Oct 30, 2017

jenkins, test it

@andrewkroh andrewkroh merged commit b8b7f8a into elastic:master Oct 30, 2017
ruflin pushed a commit to ruflin/beats that referenced this pull request Nov 28, 2017
* Make python tests not executables

Turns out that if a `test_*.py` file is executable, nosetests
doesn't pick it up, so the tests are not executed on Linux/Mac.
This was the case with two files in Filebeat.

This adds a `make check` check to look for such files, so this
doesn't happen in the future.

(cherry picked from commit b8b7f8a)
@ruflin ruflin removed the needs_backport PR is waiting to be backported to other branches. label Nov 28, 2017
exekias pushed a commit that referenced this pull request Nov 28, 2017
* Make python tests not executables

Turns out that if a `test_*.py` file is executable, nosetests
doesn't pick it up, so the tests are not executed on Linux/Mac.
This was the case with two files in Filebeat.

This adds a `make check` check to look for such files, so this
doesn't happen in the future.

(cherry picked from commit b8b7f8a)
leweafan pushed a commit to leweafan/beats that referenced this pull request Apr 28, 2023
* Make python tests not executables

Turns out that if a `test_*.py` file is executable, nosetests
doesn't pick it up, so the tests are not executed on Linux/Mac.
This was the case with two files in Filebeat.

This adds a `make check` check to look for such files, so this
doesn't happen in the future.

(cherry picked from commit baa09e8)
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.

4 participants