fix(office/fetch): stale integration-тест loader.TaskFields — ломает сборку -tags=integration #67

Closed
opened 2026-09-16 22:50:44 +01:00 by eSlider · 0 comments
Owner

Поднято при W5/W6 (#62/#63). Блокирует DoD «go test -tags=integration ./... зелёный».

Симптом

$ go test -tags=integration ./cmd/office/fetch/
cmd/office/fetch/task_integration_test.go:60:29: loader.TaskFields undefined
(type *fetch.Loader has no field or method TaskFields)
FAIL github.com/eslider/go-onlyoffice/cmd/office/fetch [build failed]

Обычный go build ./... зелёный — ломается только integration-tag сборка.

Причина

Тест TestIntegrationTaskFieldsFromLiveAPI (cmd/office/fetch/task_integration_test.go:48)
зовёт loader.TaskFields(ctx, item), которого больше нет. Актуальное API:
DetailForm / SaveItem / UpdateTask + model.FormFields (cmd/office/fetch/save.go,
task.go, list.go). Тест не обновляли после рефакторинга (последние коммиты по файлу —
0ed2d9b, 3b47d14).

Критерии приёмки

  • go test -tags=integration ./... собирается (без кред — clean skip).
  • TestIntegrationTaskFieldsFromLiveAPI переписан на текущее API (DetailForm/
    SaveItem/UpdateTask), либо заменён эквивалентным по смыслу.
  • Юнит-набор go test ./... остаётся зелёным.
Поднято при W5/W6 (#62/#63). Блокирует DoD «`go test -tags=integration ./...` зелёный». ## Симптом ``` $ go test -tags=integration ./cmd/office/fetch/ cmd/office/fetch/task_integration_test.go:60:29: loader.TaskFields undefined (type *fetch.Loader has no field or method TaskFields) FAIL github.com/eslider/go-onlyoffice/cmd/office/fetch [build failed] ``` Обычный `go build ./...` зелёный — ломается только integration-tag сборка. ## Причина Тест `TestIntegrationTaskFieldsFromLiveAPI` (`cmd/office/fetch/task_integration_test.go:48`) зовёт `loader.TaskFields(ctx, item)`, которого больше нет. Актуальное API: `DetailForm` / `SaveItem` / `UpdateTask` + `model.FormFields` (`cmd/office/fetch/save.go`, `task.go`, `list.go`). Тест не обновляли после рефакторинга (последние коммиты по файлу — `0ed2d9b`, `3b47d14`). ## Критерии приёмки - [ ] `go test -tags=integration ./...` собирается (без кред — clean skip). - [ ] `TestIntegrationTaskFieldsFromLiveAPI` переписан на текущее API (`DetailForm`/ `SaveItem`/`UpdateTask`), либо заменён эквивалентным по смыслу. - [ ] Юнит-набор `go test ./...` остаётся зелёным.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: eSlider/go-onlyoffice#67