Skip to content

Commit

Permalink
JNG-6022 Mark selected range items in http header (#350)
Browse files Browse the repository at this point in the history
[2025-02-21 00:07:12 +0100] Removing unused parameter
[2025-02-20 07:57:42 +0100] JNG-6022 [Release] Updating versions
[2025-02-16 23:06:21 +0100] Remove unused parameter
[2025-02-16 09:36:02 +0100] Change default behaviour
[2025-02-15 23:18:23 +0100] JNG-6022 Range API fix
  • Loading branch information
robertcsakany authored Feb 21, 2025
1 parent bc49458 commit e9ae80b
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 19 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,6 @@
@Slf4j
public class JudoRuntimeFixture {


public static final String MARK_SELECTED_RANGE_ITEMS = "markSelectedRangeItems";

static {
SLF4JBridgeHandler.install();
SysOutOverSLF4J.sendSystemOutAndErrToSLF4J();
Expand All @@ -52,10 +49,6 @@ public JudoRuntimeFixture(Map<String, Object> context) {
if (context == null) {
return;
}

if (context.containsKey(MARK_SELECTED_RANGE_ITEMS)) {
this.markSelectedRangeItems = (Boolean) context.get(MARK_SELECTED_RANGE_ITEMS);
}
}

public JudoRuntimeFixture() {}
Expand Down Expand Up @@ -83,8 +76,6 @@ public JudoRuntimeFixture() {}

QueryFactory queryFactory;

Boolean markSelectedRangeItems = false;

private void initQueryFactory() {

coercer = new DefaultCoercer();
Expand Down Expand Up @@ -151,8 +142,7 @@ public void init(Module module, Object injectModulesTo) {
.injectModulesTo(injectModulesTo)
.judoModelLoader(modelHolder)
.extendableCoercer(coercer)
.queryFactory(queryFactory)
.rdbmsDaoMarkSelectedRangeItems(markSelectedRangeItems);
.queryFactory(queryFactory);

Module modules = Modules.combine(
module,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -362,7 +362,7 @@ void testTwoWayAssociationAlongWithCompositionTest() {
assertEquals(bankAccount2.identifier().getIdentifier(), mappedCompanyDao.queryMainBankAccounts(company).orElseThrow().identifier().getIdentifier());

//Give back the range elements
List<MappedBankAccount> rangeOfMainBankAccounts = mappedCompanyDao.getRangeOfMainBankAccounts(company, MappedBankAccountMask.mappedBankAccountMask());
List<MappedBankAccount> rangeOfMainBankAccounts = mappedCompanyDao.getRangeOfMainBankAccounts(company, MappedBankAccountMask.mappedBankAccountMask(), false);
assertEquals(2, rangeOfMainBankAccounts.size());

// Check range validation
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,6 @@
import java.util.stream.Collectors;
import java.util.stream.IntStream;

import static hu.blackbelt.judo.runtime.core.jsl.fixture.JudoRuntimeFixture.MARK_SELECTED_RANGE_ITEMS;
import static org.hamcrest.CoreMatchers.equalTo;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.*;
Expand All @@ -119,10 +118,8 @@
@Slf4j
public class TransferRangeTest {

final static Map<String, Object> context = new HashMap<>(Map.of(MARK_SELECTED_RANGE_ITEMS, true));

@RegisterExtension
static JudoRuntimeExtension runtimeExtension = new JudoRuntimeExtension("TransferRange", new TransferRangeDaoModules(), context);
static JudoRuntimeExtension runtimeExtension = new JudoRuntimeExtension("TransferRange", new TransferRangeDaoModules(), null);

@Inject
AppleDao appleDao;
Expand Down
6 changes: 3 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,9 @@
javax.resource;version="[1.6,2)"
</osgi-transaction-import>

<judo-tatami-jsl-version>1.1.4.20250221_104148_e8c34e89_develop</judo-tatami-jsl-version>
<judo-runtime-core-version>1.0.6.20250221_043813_7b9a05c1_develop</judo-runtime-core-version>
<judo-psm-generator-sdk-core-version>1.0.0.20250221_042951_90f5ce14_develop</judo-psm-generator-sdk-core-version>
<judo-tatami-jsl-version>1.1.4.20250220_065353_f0a9d70a_feature_JNG_6022_markSelectedRangeItemsInHttpHeader</judo-tatami-jsl-version>
<judo-runtime-core-version>1.0.6.20250219_213542_c004c8d9_feature_JNG_6022_markSelectedRangeItemsInHttpHeader</judo-runtime-core-version>
<judo-psm-generator-sdk-core-version>1.0.0.20250219_212818_b1445f9d_feature_JNG_6022_markSelectedRangeItemsInHttpHeader</judo-psm-generator-sdk-core-version>

<judo-meta-psm-version>1.3.0.20250221_042033_8f97f546_develop</judo-meta-psm-version>

Expand Down

0 comments on commit e9ae80b

Please sign in to comment.