MCPcopy Create free account
hub / github.com/dim-an/cod / TestUpdateNoChange

Function TestUpdateNoChange

test/update_test.go:94–112  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

92}
93
94func TestUpdateNoChange(t *testing.T) {
95 wb := SetupWorkbench(t)
96 defer wb.Close()
97
98 shellPid := strconv.Itoa(wb.LaunchFakeShell())
99
100 wb.RunCodCmd("init", shellPid, "bash")
101
102 wb.RunCodCmd("learn", "--", "binaries/cat.py", "--help")
103 out := wb.RunCodCmd("list")
104 parsed := wb.ParseCodListMap(out)
105 require.Equal(t, len(parsed), 1)
106
107 wb.RunCodCmd("update", "**")
108
109 out = wb.RunCodCmd("list")
110 parsed = wb.ParseCodListMap(out)
111 require.Equal(t, len(parsed), 1)
112}
113
114func TestUpdateBroken(t *testing.T) {
115 wb := SetupWorkbench(t)

Callers

nothing calls this directly

Calls 5

SetupWorkbenchFunction · 0.85
LaunchFakeShellMethod · 0.80
RunCodCmdMethod · 0.80
ParseCodListMapMethod · 0.80
CloseMethod · 0.65

Tested by

no test coverage detected