Skip to content

WA-CI-006: Fix next branch CI baseline failures #748

@kitcommerce

Description

@kitcommerce

Summary

The next branch has been failing CI consistently since 2026-03-02 with multiple issues.

Objective

Restore green CI on the next branch so the review pipeline can function.

Root Causes

1. Rubocop: 980 Layout/EmptyLineAfterMagicComment offenses (auto-correctable)

2. MiddlewareStackTest failures (3 tests)

  • Introduced by: PR WA-NEW-040: Fix Rack::Attack compatibility with Rails 7 / Rack 3 #731 (WA-NEW-040: Rack::Attack), merged 2026-03-02
  • Tests expect Rack::Attack at index 3 but it is at index 1
  • Actual: ["Rack::Sendfile", "Rack::Attack", "Rack::Timeout", ...]
  • Fix: Middleware initializer ordering or test expectations need adjustment
  • Files: core/test/integration/workarea/middleware_stack_test.rb and Rack::Attack initializer

3. PublishingIntegrationTest / SegmentOverridesIntegrationTest failures

  • BSON::ObjectId comparison failures — hardcoded IDs in expected output vs actual
  • May be flaky tests or fixtures that changed; needs investigation

Acceptance Criteria

  • bundle exec rubocop passes with zero offenses on next
  • MiddlewareStackTest all 3 failing tests pass
  • PublishingIntegrationTest#test_publishing passes
  • SegmentOverridesIntegrationTest#test_creates_segment_overrides passes
  • Full CI green on next branch

Verification Plan

  1. bundle exec rubocop --autocorrect
  2. bundle exec rails test core/test/integration/workarea/middleware_stack_test.rb
  3. Push to next and verify CI passes

Client impact

None — test/lint fixes only, no behavior changes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions