Skip test when filesystem does not have xattr

Addresses regression from a104944 seen on CloudBees.
This commit is contained in:
Andrew Gaul 2014-09-05 16:25:57 -07:00
parent e1a5c521c5
commit 7869d92b29
1 changed files with 5 additions and 3 deletions

View File

@ -16,7 +16,7 @@
*/
package org.jclouds.filesystem.strategy.internal;
import static org.jclouds.utils.TestUtils.isMacOSX;
import static java.nio.file.Files.getFileStore;
import static org.jclouds.utils.TestUtils.randomByteSource;
import static org.testng.Assert.assertEquals;
import static org.testng.Assert.assertFalse;
@ -27,6 +27,8 @@ import static org.testng.Assert.fail;
import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
import java.nio.file.Paths;
import java.nio.file.attribute.UserDefinedFileAttributeView;
import java.util.Iterator;
import java.util.List;
import java.util.Set;
@ -531,8 +533,8 @@ public class FilesystemStorageStrategyImplTest {
}
public void testOverwriteBlobMetadata() throws Exception {
if (isMacOSX()) {
throw new SkipException("blob metadata not supported on Mac OS X");
if (!getFileStore(Paths.get(TestUtils.TARGET_BASE_DIR)).supportsFileAttributeView(UserDefinedFileAttributeView.class)) {
throw new SkipException("Filesystem does not support xattr");
}
String blobKey = TestUtils.createRandomBlobKey("writePayload-", ".img");