Skip to content

Conversation

@fabriziodemaria
Copy link
Member

@fabriziodemaria fabriziodemaria commented Nov 6, 2025

This means moving away from Resolve towards ResolveWithSticky

Behaviour

Sticky rules will cause an erroneous evaluation with error message "missing materialization". Before the flag would just be marked as "Not found".
Note that no Materialization solution is added yet, so sticky rules are still not supported: only the error message is improved at this stage

Tests

  • Added integration tests at the provider level in local_resolver_provider_resolve_test.go‎.
  • Added two more tests at the wasm resolver level:
    • TestSwapWasmResolverApi_ResolveFlagWithNoStickyRules
    • TestSwapWasmResolverApi_ResolveFlagWithStickyRules_MissingMaterializations

fabriziodemaria and others added 8 commits November 6, 2025 15:57
- Remove duplicate tests between local_resolver_provider_resolve_test.go and swap_wasm_resolver_api_test.go
- Remove non-sticky-related tests (TypeMismatch, InvalidClientSecret, NestedValues) as they're not relevant to the PR's focus on sticky rules error messaging
- Fix naming consistency: rename TestResolverApi_* to TestSwapWasmResolverApi_* for consistency
- Improve test names: "MinimalState" → "NonExistentFlag", "Basic" → "DirectInstanceCall"
- Simplify TestLocalResolverProvider_MissingMaterializations to focus on provider-level behavior

The main test coverage for missing materializations is now in TestSwapWasmResolverApi_ResolveWithSticky_MissingMaterializations which validates the actual response structure.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <[email protected]>
@fabriziodemaria fabriziodemaria merged commit 31a6893 into main Nov 7, 2025
10 checks passed
@fabriziodemaria fabriziodemaria deleted the sticky-error-msg branch November 7, 2025 13:08
This was referenced Nov 7, 2025
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.

3 participants