(t *testing.T)
| 115 | } |
| 116 | |
| 117 | func TestLocalComplete(t *testing.T) { //nolint:dupl |
| 118 | path, err := mockPath() |
| 119 | if err != nil { |
| 120 | t.Fatal(err) |
| 121 | } |
| 122 | |
| 123 | zip, err := filepath.Abs(filepath.Join(TestData, "ISC.zip")) |
| 124 | if err != nil { |
| 125 | t.Fatal(err) |
| 126 | } |
| 127 | |
| 128 | err = readPkg(zip, path, 0) |
| 129 | if err != nil { |
| 130 | t.Fatal(err) |
| 131 | } |
| 132 | |
| 133 | if !system.IsDir(filepath.Join(path, "ISC")) { |
| 134 | t.Fatal("unable to find 'ISC' in StylesPath") |
| 135 | } |
| 136 | |
| 137 | vocab := filepath.Join(path, "Vocab", "ISC_General", "accept.txt") |
| 138 | if !system.FileExists(vocab) { |
| 139 | t.Fatal("unable to find 'ISC_General' in Vocab") |
| 140 | } |
| 141 | |
| 142 | b, err := os.ReadFile(vocab) |
| 143 | if err != nil { |
| 144 | t.Fatal(err) |
| 145 | } |
| 146 | lines := strings.Split(string(b), "\n") |
| 147 | |
| 148 | if !core.StringInSlice("bar", lines) { |
| 149 | t.Fatalf("unable to find 'bar' in %v", lines) |
| 150 | } |
| 151 | } |
| 152 | |
| 153 | func TestLocalOnlyStyles(t *testing.T) { //nolint:dupl |
| 154 | path, err := mockPath() |
nothing calls this directly
no test coverage detected
searching dependent graphs…