Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
dms3
go-ds-flatfs
Commits
40b83ce5
Commit
40b83ce5
authored
May 03, 2018
by
Steven Allen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix go-vet errors
parent
2975b378
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
convert_test.go
convert_test.go
+5
-5
No files found.
convert_test.go
View file @
40b83ce5
...
...
@@ -83,13 +83,13 @@ func TestMoveRestart(t *testing.T) {
// try the move it should fail partly through
err
=
flatfs
.
Move
(
v1dir
,
v2dir
,
nil
)
if
err
==
nil
{
t
.
Fatal
f
(
"Move should have failed."
,
err
)
t
.
Fatal
(
"Move should have failed."
,
err
)
}
// okay try to undo should be okay
err
=
flatfs
.
Move
(
v2dir
,
v1dir
,
nil
)
if
err
!=
nil
{
t
.
Fatal
f
(
"Could not undo the move."
,
err
)
t
.
Fatal
(
"Could not undo the move."
,
err
)
}
checkKeys
(
t
,
v1dir
,
keys
,
blocks
)
...
...
@@ -100,7 +100,7 @@ func TestMoveRestart(t *testing.T) {
createDatastore
(
t
,
v2dir
,
flatfs
.
NextToLast
(
2
))
err
=
flatfs
.
Move
(
v1dir
,
v2dir
,
nil
)
if
err
==
nil
{
t
.
Fatal
f
(
"Move should have failed."
,
err
)
t
.
Fatal
(
"Move should have failed."
,
err
)
}
// fix the permission problem
...
...
@@ -150,7 +150,7 @@ func TestUpgradeDownload(t *testing.T) {
_
,
err
=
os
.
Stat
(
filepath
.
Join
(
tempdir
,
flatfs
.
SHARDING_FN
))
if
err
==
nil
{
t
.
Fatalf
(
"%v not in v0 format, SHARDING FILE exists"
)
t
.
Fatalf
(
"%v not in v0 format, SHARDING FILE exists"
,
tempdir
)
}
else
if
!
os
.
IsNotExist
(
err
)
{
t
.
Fatalf
(
"Stat fail: %v
\n
"
,
err
)
}
...
...
@@ -172,7 +172,7 @@ func TestDownloadNonPrefix(t *testing.T) {
err
:=
flatfs
.
DowngradeV1toV0
(
tempdir
)
if
err
==
nil
{
t
.
Fatal
f
(
"DowngradeV1toV0 should have failed"
,
err
)
t
.
Fatal
(
"DowngradeV1toV0 should have failed"
,
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