Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Ops] Make unit-test agent agnostic (elastic#174441)
## Summary This is not an error now but will be required for elastic/kibana-operations#15 - this solution should work in both scenarios, so it can be done up-front. Quote from Brian's notes regarding buildkite migration: >The buildkite-agent process is running with a different umask in the new system. Files are being created with slightly different permissions by default. For example, when the kibana repo is checked out, files have 664 permissions instead of 644. This shouldn’t cause any major issues for Kibana, BUT a few tests check the permission flags on files during a copy process. They should probably be changed to check the permissions on the source file rather than just hard-coding them. This is showing up in the unit tests like this: ``` FAIL src/cli_plugin/install/zip.test.js -- | ● kibana cli › zip › checkFilePermission › verify consistency of modes of files | | expect(received).toEqual(expected) // deep equality | | Expected: "755" | Received: "775" ``` We can't access the source files inside the zip file, the rights will only be revealed after unzipping. However, the difference in the default access rights is in the RW and not the X, which we're really curious about. So as a solution, I'm only checking if the executable file is indeed executable by all, and the non-executable is not executable by anyone.
- Loading branch information