Skip to content

Commit 5aef1cb

Browse files
committed
test: Add maintenance key bypass test for subqueryLimit
1 parent 9421f03 commit 5aef1cb

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

spec/RequestComplexity.spec.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -814,6 +814,16 @@ describe('request complexity', () => {
814814
expect(result.results.length).toBe(totalObjects);
815815
});
816816

817+
it('should allow unlimited subquery results with maintenance key', async () => {
818+
const where = {
819+
ref: {
820+
$inQuery: { className: 'Target', where: {} },
821+
},
822+
};
823+
const result = await rest.find(config, auth.maintenance(config), 'Source', where);
824+
expect(result.results.length).toBe(totalObjects);
825+
});
826+
817827
it('should allow unlimited subquery results when subqueryLimit is -1', async () => {
818828
await reconfigureServer({
819829
requestComplexity: { subqueryLimit: -1 },

0 commit comments

Comments
 (0)