Closed bobrik closed 8 years ago
I'm getting some conflicts with the test:
1) LogStash::Outputs::File receiving events output string format when using file and dir modes dirs and files are created with correct permissions
Failure/Error: expect(File.stat(first_good_dir).mode.to_s(8)).to eq('100750')
expected: "100750"
got: "40750"
This may be because I'm testing on OS X, but that is an acceptable runtime environment.
It's doing the same thing on my Ubuntu 14.04 box:
Failures:
1) LogStash::Outputs::File receiving events output string format when using file and dir modes dirs and files are created with correct permissions
Failure/Error: expect(File.stat(first_good_dir).mode.to_s(8)).to eq('100750')
expected: "100750"
got: "40750"
(compared using ==)
I'm on OS X as well:
$ stat -f %p README.md
100644
I'm thinking about dropping anything above the third octet in the test. What do you think?
I think the umask should be limited to the last octet. If doing so, would you please change or add a few other tests to use atypical masks? 750 and 644 are common enough that they could generate a false positive.
Updated with atypical mode.
Also rebased and added changelog entry.
Improving the documentation examples would be all that's left to make this right.
Added backticks
Excellent! Merging now.
Aaron Mildenstein merged this into the following branches!
Branch | Commits |
---|---|
master | bd860c2d6dca30dd747f1ea0e9b1b915eb57f6dc |
Disclaimer: I don't know ruby.