MCPcopy Create free account
hub / github.com/diillson/chatcli / TestHandleWrite_Validation

Function TestHandleWrite_Validation

pkg/coder/engine/commands_fs_test.go:60–68  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

58}
59
60func TestHandleWrite_Validation(t *testing.T) {
61 e, _, _ := newWsEngine(t)
62 if err := e.Execute(context.Background(), "write", []string{"--content", "x"}); err == nil {
63 t.Error("expected error for missing --file")
64 }
65 if err := e.Execute(context.Background(), "write", []string{"--file", "f.txt"}); err == nil {
66 t.Error("expected error for empty --content")
67 }
68}
69
70func TestHandleWrite_DecodeError(t *testing.T) {
71 e, _, root := newWsEngine(t)

Callers

nothing calls this directly

Calls 3

newWsEngineFunction · 0.85
ExecuteMethod · 0.65
ErrorMethod · 0.65

Tested by

no test coverage detected