summaryrefslogtreecommitdiff
path: root/internal/fusefrontend/xattr_linux_unit_test.go
diff options
context:
space:
mode:
authorbolshevik2018-04-17 20:33:04 +0200
committerrfjakob2018-04-17 20:33:04 +0200
commit12b32aa06c0475d60ee51b3753052ac2e4d09308 (patch)
tree2b880d5e2a96f0992e9ba0fc54df85a6a18969ae /internal/fusefrontend/xattr_linux_unit_test.go
parent12832851c68ce6ba2907b5d5fefc2a5e49f7c36a (diff)
Improved xattr handling on non-linux systems (#227)
* Fixed xattr filtering for MacOS. "system." and "user." prefixes are only relevant for Linux. * Small cleanup and additional tests.
Diffstat (limited to 'internal/fusefrontend/xattr_linux_unit_test.go')
-rw-r--r--internal/fusefrontend/xattr_linux_unit_test.go13
1 files changed, 13 insertions, 0 deletions
diff --git a/internal/fusefrontend/xattr_linux_unit_test.go b/internal/fusefrontend/xattr_linux_unit_test.go
new file mode 100644
index 0000000..5fea58b
--- /dev/null
+++ b/internal/fusefrontend/xattr_linux_unit_test.go
@@ -0,0 +1,13 @@
+// +build linux
+
+package fusefrontend
+
+import (
+ "testing"
+)
+
+func TestDisallowedLinuxAttributes(t *testing.T) {
+ if !disallowedXAttrName("xxxx") {
+ t.Fatalf("Names that don't start with 'user.' should fail")
+ }
+}