Skip to content

test(grok): align golden expectations with native safety - #1019

Merged
777genius merged 1 commit into
mainfrom
fix/grok-golden-contract-cdcf
Nov 19, 2026
Merged

777genius merged 1 commit into
mainfrom
fix/grok-golden-contract-cdcf

Conversation

@777genius

Copy link
Copy Markdown
Owner

Problem

The native safety changes merged in #995 left three provider golden expectations behind. The real core job 135560805023 failed because the old expectations still allowed artifact removal without a successful absence observation. The same branch also retained one gofmt alignment issue.

Changes

  • Bring three Grok golden records into agreement with the existing strict behavior: malformed inventory fails normal activation; unknown inventory retains the managed artifact; a still-present plugin after unregister retains the artifact and reports an uncertain native effect.
  • Finish the remaining map-key alignment in the foreign-source regression test.

The JSON bytes come directly from the canonical test renderer's retained CI output. Before accepting each current payload, its recorded payload was checked byte-for-byte against the existing main golden, including escaping, root normalization and the final newline. Exactly eight Grok fields change; the other 16 client records, command arguments, production code, fixtures and safety checks stay exact.

Base: cdcf3831ae5674ec8e9c3463dcd227cf4c65a99c. Candidate: f9a8ae52d5b09c5029d9ea04e10a80054fbe743c, tree a42072f4780a6588f79b6499047841cb818f5da3.

Verification

  • Independent source review, canonical generated-data comparison, exact four-file scope and git diff --check.
  • One focused inert run on the candidate: six existing Grok activation/removal/foreign-source methods, 24 results including subtests, zero failures or skips. Go 1.26.11; 7.019 seconds; natural completion without signals or timeout.
  • Current-commit hosted provider/core and lint checks: pending and required. The prior failing job is retained as the causal evidence.
  • go test ./..., local full make lint, make vet, make generated-check and make test-core: not repeated for this generated-test-data and whitespace-only correction. The known unrelated local Codex environment refusal was not bypassed, and no blind UPDATE_GOLDEN run was used.
  • Native lifecycle qualification: not established by these inert tests; no executable behavior changes in this PR.

Release Impact

Preserve the strict catalog/readback behavior introduced by #995. Use the canonical CI-rendered outputs for its three provider golden cases and finish the remaining gofmt alignment. Production code and all other client expectations are unchanged.
@strix-security

Copy link
Copy Markdown

Strix is installed on this repository, but we couldn't run this PR security review because this workspace's trial has ended. Add a card to resume code reviews here.

So far, Strix has reviewed 392 pull requests, surfaced 113 security issues (1 critical/high) and blocked 3 risky merges across this workspace.

@coderabbitai

coderabbitai Bot commented Nov 19, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 5 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

Commits

Reviewing files that changed from the base of the PR and between cdcf383 and f9a8ae5.

Files selected for processing: 4

  • install/integrationctl/agentplugins/clients/grok/project_skill_foreign_sources_test.go
  • install/integrationctl/agentplugins/providers/testdata/golden/activate.json
  • install/integrationctl/agentplugins/providers/testdata/golden/deactivate_confirmed.json
  • install/integrationctl/agentplugins/providers/testdata/golden/deactivate_recorded_ownership.json
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@777genius
777genius merged commit 0c85dbf into main Nov 19, 2026
75 of 76 checks passed
@777genius
777genius deleted the fix/grok-golden-contract-cdcf branch November 19, 2026 14:02
@codecov

codecov Bot commented Nov 19, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 63.49%. Comparing base (795d793) to head (f9a8ae5).
⚠️ Report is 116 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1019      +/-   ##
==========================================
+ Coverage   63.45%   63.49%   +0.04%     
==========================================
  Files        2279     2281       +2     
  Lines      137250   137405     +155     
==========================================
+ Hits        87094    87251     +157     
+ Misses      37597    37590       -7     
- Partials    12559    12564       +5     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant