MCPcopy Create free account
hub / github.com/castai/openwebui-content-sync / TestFile_String

Function TestFile_String

internal/adapter/github_test.go:160–182  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

158}
159
160func TestFile_String(t *testing.T) {
161 file := &File{
162 Path: "test.md",
163 Hash: "abc123",
164 Size: 100,
165 Source: "github",
166 Modified: time.Now(),
167 }
168
169 // Test that File struct can be created and accessed
170 if file.Path != "test.md" {
171 t.Errorf("Expected path 'test.md', got '%s'", file.Path)
172 }
173 if file.Hash != "abc123" {
174 t.Errorf("Expected hash 'abc123', got '%s'", file.Hash)
175 }
176 if file.Size != 100 {
177 t.Errorf("Expected size 100, got %d", file.Size)
178 }
179 if file.Source != "github" {
180 t.Errorf("Expected source 'github', got '%s'", file.Source)
181 }
182}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected