From 2e512e81c92b44ba6a4a86b36b9de8dd35f7dc53 Mon Sep 17 00:00:00 2001
From: Brian Tiger Chow <brian.holderchow@gmail.com>
Date: Fri, 12 Sep 2014 04:36:07 -0700
Subject: [PATCH] test(config) add path assertion

---
 config/config_test.go | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/config/config_test.go b/config/config_test.go
index edbc1c764..c891d6c51 100644
--- a/config/config_test.go
+++ b/config/config_test.go
@@ -1,13 +1,14 @@
 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()
+	}
 }
-- 
GitLab