20 lines
455 B
Go
20 lines
455 B
Go
|
package util
|
||
|
|
||
|
import "testing"
|
||
|
|
||
|
func TestResolveTilde(t *testing.T) {
|
||
|
resolvedPath := ResolveTilde("~")
|
||
|
|
||
|
if resolvedPath == "~" {
|
||
|
t.Logf("ResolveTilde returned '%s'; it should have expanded to an absolute path.", resolvedPath)
|
||
|
}
|
||
|
}
|
||
|
|
||
|
func TestResolveTildePath(t *testing.T) {
|
||
|
resolvedPath := ResolveTilde("~/test")
|
||
|
|
||
|
if resolvedPath == "~/test" {
|
||
|
t.Logf("ResolveTilde returned '%s'; it should have expanded to an absolute path.", resolvedPath)
|
||
|
}
|
||
|
}
|