// Copyright 2024 Matthew Rich . All rights reserved. package folio import ( "github.com/stretchr/testify/assert" "testing" "os" ) func TestSearchPath(t *testing.T) { assert.Nil(t, TempDir.CreateFile("test.jx.yaml", "")) sp := NewSearchPath(nil) assert.NotNil(t, sp) assert.Nil(t, sp.AddPath(string(TempDir))) absPath := sp.Find("test.jx.yaml") _, err := os.Stat(absPath) assert.True(t, !os.IsNotExist(err)) }