MCPcopy
hub / github.com/wagoodman/dive / runTestCase

Function runTestCase

runtime/ui/viewmodel/filetree_test.go:101–113  ·  view source on GitHub ↗
(t *testing.T, vm *FileTreeViewModel, width, height int, filterRegex *regexp.Regexp)

Source from the content-addressed store, hash-verified

99}
100
101func runTestCase(t *testing.T, vm *FileTreeViewModel, width, height int, filterRegex *regexp.Regexp) {
102 err := vm.Update(filterRegex, width, height)
103 if err != nil {
104 t.Errorf("failed to update viewmodel: %v", err)
105 }
106
107 err = vm.Render()
108 if err != nil {
109 t.Errorf("failed to render viewmodel: %v", err)
110 }
111
112 assertTestData(t, vm.Buffer.Bytes())
113}
114
115func checkError(t *testing.T, err error, message string) {
116 if err != nil {

Callers 14

TestFileTreeGoCaseFunction · 0.85
TestFileTreeNoAttributesFunction · 0.85
TestFileTreeDirCollapseFunction · 0.85
TestFileTreeSelectLayerFunction · 0.85
TestFileTreePageDownFunction · 0.85
TestFileTreePageUpFunction · 0.85
TestFileTreeFilterTreeFunction · 0.85

Calls 3

assertTestDataFunction · 0.85
UpdateMethod · 0.65
RenderMethod · 0.65

Tested by

no test coverage detected