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-unixfs
Commits
2e512e81
Commit
2e512e81
authored
Sep 12, 2014
by
Brian Tiger Chow
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test(config) add path assertion
parent
a5c0f67c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
config/config_test.go
config/config_test.go
+5
-3
No files found.
config/config_test.go
View file @
2e512e81
package
config
import
(
"fmt"
"testing"
)
func
TestConfig
(
t
*
testing
.
T
)
{
const
filename
=
".ipfsconfig"
const
dsPath
=
"/path/to/datastore"
cfgWritten
:=
new
(
Config
)
cfgWritten
.
Datastore
.
Path
=
dsPath
err
:=
WriteConfigFile
(
filename
,
cfgWritten
)
if
err
!=
nil
{
t
.
Error
(
err
)
...
...
@@ -17,6 +18,7 @@ func TestConfig(t *testing.T) {
t
.
Error
(
err
)
return
}
fmt
.
Printf
(
cfgRead
.
Datastore
.
Path
)
if
cfgWritten
.
Datastore
.
Path
!=
cfgRead
.
Datastore
.
Path
{
t
.
Fail
()
}
}
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