MCPcopy Create free account
hub / github.com/vale-cli/vale / TestLocalDir

Function TestLocalDir

cmd/vale/pkg_test.go:92–115  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

90}
91
92func TestLocalDir(t *testing.T) {
93 path, err := mockPath()
94 if err != nil {
95 t.Fatal(err)
96 }
97
98 zip, err := filepath.Abs(filepath.Join(TestData, "write-good"))
99 if err != nil {
100 t.Fatal(err)
101 }
102
103 err = readPkg(zip, path, 0)
104 if err != nil {
105 t.Fatal(err)
106 }
107
108 if !system.IsDir(filepath.Join(path, "write-good")) {
109 t.Fatal("unable to find 'write-good' in StylesPath")
110 }
111
112 if !system.FileExists(filepath.Join(path, "write-good", "E-Prime.yml")) {
113 t.Fatal("unable to find 'E-Prime' in StylesPath")
114 }
115}
116
117func TestLocalComplete(t *testing.T) { //nolint:dupl
118 path, err := mockPath()

Callers

nothing calls this directly

Calls 4

IsDirFunction · 0.92
FileExistsFunction · 0.92
mockPathFunction · 0.85
readPkgFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…