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-dms3
Commits
310c08cf
Commit
310c08cf
authored
Jan 20, 2017
by
Zander Mackie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update Version to reflect fsrepo change
License: MIT Signed-off-by:
Zander Mackie
<
zmackie@gmail.com
>
parent
fef5d5bb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
3 deletions
+6
-3
repo/fsrepo/migrations/mfsr_test.go
repo/fsrepo/migrations/mfsr_test.go
+6
-3
No files found.
repo/fsrepo/migrations/mfsr_test.go
View file @
310c08cf
...
...
@@ -3,6 +3,7 @@ package mfsr
import
(
"io/ioutil"
"os"
"strconv"
"testing"
"github.com/ipfs/go-ipfs/thirdparty/assert"
...
...
@@ -28,13 +29,15 @@ func TestVersion(t *testing.T) {
t
.
Fatalf
(
"Should throw an `IsNotExist` error when file doesn't exist: %v"
,
err
)
}
rp
=
testVersionFile
(
"4"
,
t
)
fsrepoV
:=
5
rp
=
testVersionFile
(
strconv
.
Itoa
(
fsrepoV
),
t
)
_
,
err
=
rp
.
Version
()
assert
.
Err
(
err
,
t
,
"Bad VersionFile"
)
assert
.
Nil
(
rp
.
WriteVersion
(
4
),
t
,
"Trouble writing version"
)
assert
.
Nil
(
rp
.
WriteVersion
(
fsrepoV
),
t
,
"Trouble writing version"
)
assert
.
Nil
(
rp
.
CheckVersion
(
4
),
t
,
"Trouble checking the verion"
)
assert
.
Nil
(
rp
.
CheckVersion
(
fsrepoV
),
t
,
"Trouble checking the verion"
)
assert
.
Err
(
rp
.
CheckVersion
(
1
),
t
,
"Should throw an error for the wrong version."
)
}
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