Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
go-fuse
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
go-fuse
Commits
9161846d
Commit
9161846d
authored
Jun 30, 2016
by
Han-Wen Nienhuys
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove embedding of testing.T, which goes contrary to Go style.
Change-Id: Iff1b21137fdbdccc7d7fa83b619df333eab7be26
parent
aa08b0ff
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
5 deletions
+0
-5
fuse/pathfs/xattr_test.go
fuse/pathfs/xattr_test.go
+0
-5
No files found.
fuse/pathfs/xattr_test.go
View file @
9161846d
...
@@ -18,7 +18,6 @@ var xattrGolden = map[string][]byte{
...
@@ -18,7 +18,6 @@ var xattrGolden = map[string][]byte{
var
xattrFilename
=
"filename"
var
xattrFilename
=
"filename"
type
XAttrTestFs
struct
{
type
XAttrTestFs
struct
{
tester
*
testing
.
T
filename
string
filename
string
attrs
map
[
string
][]
byte
attrs
map
[
string
][]
byte
...
@@ -52,7 +51,6 @@ func (fs *XAttrTestFs) GetAttr(name string, context *fuse.Context) (*fuse.Attr,
...
@@ -52,7 +51,6 @@ func (fs *XAttrTestFs) GetAttr(name string, context *fuse.Context) (*fuse.Attr,
}
}
func
(
fs
*
XAttrTestFs
)
SetXAttr
(
name
string
,
attr
string
,
data
[]
byte
,
flags
int
,
context
*
fuse
.
Context
)
fuse
.
Status
{
func
(
fs
*
XAttrTestFs
)
SetXAttr
(
name
string
,
attr
string
,
data
[]
byte
,
flags
int
,
context
*
fuse
.
Context
)
fuse
.
Status
{
fs
.
tester
.
Log
(
"SetXAttr"
,
name
,
attr
,
string
(
data
),
flags
)
if
name
!=
fs
.
filename
{
if
name
!=
fs
.
filename
{
return
fuse
.
ENOENT
return
fuse
.
ENOENT
}
}
...
@@ -70,7 +68,6 @@ func (fs *XAttrTestFs) GetXAttr(name string, attr string, context *fuse.Context)
...
@@ -70,7 +68,6 @@ func (fs *XAttrTestFs) GetXAttr(name string, attr string, context *fuse.Context)
if
!
ok
{
if
!
ok
{
return
nil
,
fuse
.
ENODATA
return
nil
,
fuse
.
ENODATA
}
}
fs
.
tester
.
Log
(
"GetXAttr"
,
string
(
v
))
return
v
,
fuse
.
OK
return
v
,
fuse
.
OK
}
}
...
@@ -90,7 +87,6 @@ func (fs *XAttrTestFs) RemoveXAttr(name string, attr string, context *fuse.Conte
...
@@ -90,7 +87,6 @@ func (fs *XAttrTestFs) RemoveXAttr(name string, attr string, context *fuse.Conte
return
fuse
.
ENOENT
return
fuse
.
ENOENT
}
}
_
,
ok
:=
fs
.
attrs
[
attr
]
_
,
ok
:=
fs
.
attrs
[
attr
]
fs
.
tester
.
Log
(
"RemoveXAttr"
,
name
,
attr
,
ok
)
if
!
ok
{
if
!
ok
{
return
fuse
.
ENODATA
return
fuse
.
ENODATA
}
}
...
@@ -105,7 +101,6 @@ func readXAttr(p, a string) (val []byte, err error) {
...
@@ -105,7 +101,6 @@ func readXAttr(p, a string) (val []byte, err error) {
func
xattrTestCase
(
t
*
testing
.
T
,
nm
string
,
m
map
[
string
][]
byte
)
(
mountPoint
string
,
cleanup
func
())
{
func
xattrTestCase
(
t
*
testing
.
T
,
nm
string
,
m
map
[
string
][]
byte
)
(
mountPoint
string
,
cleanup
func
())
{
xfs
:=
NewXAttrFs
(
nm
,
m
)
xfs
:=
NewXAttrFs
(
nm
,
m
)
xfs
.
tester
=
t
mountPoint
,
err
:=
ioutil
.
TempDir
(
""
,
"go-fuse-xattr_test"
)
mountPoint
,
err
:=
ioutil
.
TempDir
(
""
,
"go-fuse-xattr_test"
)
if
err
!=
nil
{
if
err
!=
nil
{
t
.
Fatalf
(
"TempDir failed: %v"
,
err
)
t
.
Fatalf
(
"TempDir failed: %v"
,
err
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment