Skip to content

Conversation

@medcl
Copy link
Member

@medcl medcl commented Nov 17, 2025

What does this PR do

Rationale for this change

Standards checklist

  • The PR title is descriptive
  • The commit messages are semantic
  • Necessary tests are added
  • Updated the release notes
  • Necessary documents have been added if this is a new feature
  • Performance tests checked, no obvious performance degradation

@SteveLauC SteveLauC force-pushed the _ctx.response.body_json branch from 69e23c8 to 4c6bdb1 Compare November 17, 2025 03:36
SteveLauC added a commit to infinilabs/loadgen-dsl that referenced this pull request Nov 17, 2025
This commit allows us to do assertions against array-type response body:

```
POST /resources/shares/_batch_get
[
  {
    "resource_id": "$[[env.DATASOURCE_1_DOCUMENT_FILE_A_ID]]",
  }
]
```

This was not implemented primarily because Loadgen did not support it,
which will be solved by PR [1].

[1]: infinilabs/loadgen#41
SteveLauC added a commit to infinilabs/loadgen-dsl that referenced this pull request Nov 17, 2025
This commit allows us to do assertions against array-type response body:

```
POST /resources/shares/_batch_get
[
  {
    "resource_id": "$[[env.DATASOURCE_1_DOCUMENT_FILE_A_ID]]",
  }
]
# assert: (200,
# [
#   {
#     "permission": 8,
#     "principal_id": "$[[env.A_ID]]"
#   },
#   {
#     "permission": 4
#   }
# ])
```

This was not implemented primarily because Loadgen did not support it,
which will be solved by PR [1].

[1]: infinilabs/loadgen#41

# Please enter the commit message for your changes. Lines starting
# with '#' will be kept; you may remove them yourself if you want to.
# An empty message aborts the commit.
#
# Date:      Mon Nov 17 11:50:53 2025 +0800
#
# On branch steve/feat/array_type_response_body
# Your branch and 'origin/steve/feat/array_type_response_body' have diverged,
# and have 1 and 1 different commits each, respectively.
#
# Changes to be committed:
#	modified:   Cargo.lock
#	modified:   compiler/src/ast.rs
#	modified:   compiler/src/compiler.rs
#	modified:   dist/loadgen_dsl.wasm
#	deleted:    rust-toolchain
#	new file:   rust-toolchain.toml
#
SteveLauC added a commit to infinilabs/loadgen-dsl that referenced this pull request Nov 17, 2025
This commit allows us to do assertions against array-type response body:

```
POST /resources/shares/_batch_get
[
  {
    "resource_id": "$[[env.DATASOURCE_1_DOCUMENT_FILE_A_ID]]",
  }
]
# assert: (200,
# [
#   {
#     "permission": 8,
#     "principal_id": "$[[env.A_ID]]"
#   },
#   {
#     "permission": 4
#   }
# ])
```

This was not implemented primarily because Loadgen did not support it,
which will be solved by PR [1].

[1]: infinilabs/loadgen#41
@medcl medcl merged commit e64c8f2 into main Nov 17, 2025
5 of 6 checks passed
@medcl medcl deleted the _ctx.response.body_json branch November 17, 2025 04:08
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.

5 participants