Page MenuHomePhabricator

Add unit tests for `ArcanistChmodLinter`
ClosedPublic

Authored by joshuaspence on Jan 12 2015, 10:06 AM.
Tags
None
Referenced Files
Unknown Object (File)
May 10 2025, 1:33 PM
Unknown Object (File)
May 8 2025, 2:30 AM
Unknown Object (File)
Apr 15 2025, 1:17 PM
Unknown Object (File)
Apr 11 2025, 4:19 PM
Unknown Object (File)
Apr 10 2025, 10:18 PM
Unknown Object (File)
Feb 8 2025, 1:03 AM
Unknown Object (File)
Feb 8 2025, 1:03 AM
Unknown Object (File)
Feb 8 2025, 1:03 AM
Subscribers

Details

Summary

Moar test coverage.

Test Plan

arc unit

Diff Detail

Repository
rARC Arcanist
Branch
chmod-test
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 3781
Build 3792: [Placeholder Plan] Wait for 30 Seconds

Event Timeline

joshuaspence retitled this revision from to Add unit tests for `ArcanistChmodLinter`.
joshuaspence updated this object.
joshuaspence edited the test plan for this revision. (Show Details)
joshuaspence added a reviewer: epriestley.
epriestley edited edge metadata.
This revision is now accepted and ready to land.Jan 14 2015, 2:59 PM
src/lint/linter/ArcanistChmodLinter.php
47

I was considering whether to add an isExecutable() method to ArcanistLintEngine, but decided against it for no particular reason. It could be reasonable to add this method though.

src/lint/linter/__tests__/ArcanistLinterTestCase.php
105

Oh, one other thing I noticed is that Filesystem::changePermissions doesn't do any validation on $mode, which seems wrong to me given that PHP will do unexpected things if you pass a string to $mode (see http://php.net/manual/en/function.chmod.php#96086, for example).

This revision was automatically updated to reflect the committed changes.