Skip to content

Validate icon wire fields#256

Closed
leehack wants to merge 1 commit into
spec/elicitation-primitive-schema-validationfrom
spec/icon-wire-validation
Closed

Validate icon wire fields#256
leehack wants to merge 1 commit into
spec/elicitation-primitive-schema-validationfrom
spec/icon-wire-validation

Conversation

@leehack

@leehack leehack commented Jun 1, 2026

Copy link
Copy Markdown
Owner

Summary

  • validate McpIcon.fromJson required and optional string fields with FormatException
  • reject malformed sizes arrays and unknown theme enum values instead of silently dropping them
  • add direct and nested regression coverage for icon wire parsing

Validation

  • dart format lib/src/types/content.dart test/types_test.dart
  • dart analyze
  • dart test test/types_test.dart
  • dart test test/mcp_2025_11_25_test.dart
  • dart test test/mcp_2026_07_28_test.dart
  • git diff --check
  • dart test

@codecov

codecov Bot commented Jun 1, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 88.55%. Comparing base (1e1892b) to head (38b2752).

Additional details and impacted files
@@                               Coverage Diff                                @@
##           spec/elicitation-primitive-schema-validation     #256      +/-   ##
================================================================================
+ Coverage                                         88.53%   88.55%   +0.01%     
================================================================================
  Files                                                47       47              
  Lines                                              9405     9421      +16     
================================================================================
+ Hits                                               8327     8343      +16     
  Misses                                             1078     1078              
Flag Coverage Δ
unittests 88.55% <100.00%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 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.

@leehack

leehack commented Jun 1, 2026

Copy link
Copy Markdown
Owner Author

Closing this draft micro PR because the RC spec work has been consolidated into a smaller reviewable stack. This change is preserved in #271 (type/schema validation); the consolidated tip is tree-identical to the previous micro-stack tip.

@leehack leehack closed this Jun 1, 2026
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