Skip to content

Commit

Permalink
os: skip TestHardLink on Android.
Browse files Browse the repository at this point in the history
From Android release M (Marshmallow), hard linking files is blocked
and an attempt to call link() on a file will return EACCES.
- https://code.google.com/p/android-developer-preview/issues/detail?id=3150

Change-Id: Ifdadaa31e3d5ee330553f45db6c001897dc955be
Reviewed-on: https://go-review.googlesource.com/17339
Reviewed-by: Brad Fitzpatrick <[email protected]>
Run-TryBot: Brad Fitzpatrick <[email protected]>
  • Loading branch information
Rahul Chaudhry authored and bradfitz committed Dec 3, 2015
1 parent dc94094 commit 3afee43
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/os/os_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -583,6 +583,12 @@ func TestHardLink(t *testing.T) {
if runtime.GOOS == "plan9" {
t.Skip("skipping on plan9, hardlinks not supported")
}
// From Android release M (Marshmallow), hard linking files is blocked
// and an attempt to call link() on a file will return EACCES.
// - https://code.google.com/p/android-developer-preview/issues/detail?id=3150
if runtime.GOOS == "android" {
t.Skip("skipping on android, hardlinks not supported")
}
defer chtmpdir(t)()
from, to := "hardlinktestfrom", "hardlinktestto"
Remove(from) // Just in case.
Expand Down

0 comments on commit 3afee43

Please sign in to comment.