MCPcopy
hub / github.com/perkeep/perkeep / TestOpenCamliIncludeDir

Function TestOpenCamliIncludeDir

internal/osutil/paths_test.go:95–106  ·  view source on GitHub ↗

Test for when a file exists in CAMLI_CONFIG_DIR

(t *testing.T)

Source from the content-addressed store, hash-verified

93
94// Test for when a file exists in CAMLI_CONFIG_DIR
95func TestOpenCamliIncludeDir(t *testing.T) {
96 td := t.TempDir()
97
98 const name string = "TestOpenCamliIncludeDir.config"
99 if e := createTestInclude(filepath.Join(td, name)); e != nil {
100 t.Errorf("Couldn't create test config file, aborting test: %v", e)
101 return
102 }
103 t.Setenv("CAMLI_CONFIG_DIR", td)
104
105 checkOpen(t, name)
106}
107
108// Test for when a file exits in CAMLI_INCLUDE_PATH
109func TestOpenCamliIncludePath(t *testing.T) {

Callers

nothing calls this directly

Calls 2

createTestIncludeFunction · 0.85
checkOpenFunction · 0.85

Tested by

no test coverage detected