Skip to content

Update facet configuration position and optionsLimit parameters #161

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

mocca102
Copy link
Contributor

Issue

  • position and options_limit default to zero due to type int

Fix

  • Change type from int to Integer which will default the values to null instead of zero
  • Add tests

@mocca102 mocca102 requested a review from a team June 17, 2025 12:47
@mocca102 mocca102 force-pushed the ci-4556-java-update-options_limit-and-position-types-to-integer branch from b8d0f96 to d3d4b1f Compare June 17, 2025 13:03
Copy link
Contributor

@stanlp1 stanlp1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

One comment. @mocca102 Can we add a new test that set these values as null, checksto make sure that these values are included in the serialized option?

@@ -177,12 +177,12 @@ public void testCreateFacetOptionConfigurations() throws Exception {
assertEquals("test-option", jsonOption1.get("value"));
assertEquals("test-alias", jsonOption1.get("value_alias"));
assertEquals("Test Option", jsonOption1.get("display_name"));
assertEquals(1, jsonOption1.get("position"));
assertEquals(Integer.valueOf(1), jsonOption1.get("position"));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we add a similar test to this where we set values to null, see if it gets set correctly?

@mocca102 mocca102 requested a review from stanlp1 June 25, 2025 16:18
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.

2 participants