usebruno / bruno

Opensource IDE For Exploring and Testing Api's (lightweight alternative to postman/insomnia)
https://www.usebruno.com/
MIT License
27.56k stars 1.27k forks source link

[1.34.2] isArray assertions incorrectly failing on CLI #3514

Closed fantpmas closed 19 hours ago

fantpmas commented 1 day ago

I have checked the following:

Describe the bug

isArray assertions work fine in Bruno itself but incorrectly show as failing when executed via the CLI.

.bru file to reproduce the bug

meta {
  name: todo
  type: http
  seq: 2
}

get {
  url: https://jsonplaceholder.typicode.com/todos/
  body: none
  auth: none
}

assert {
  res.body: isArray 
}

Screenshots/Live demo link

Screenshot 2024-11-20 at 09 46 32 (1) Screenshot 2024-11-20 at 09 46 05 (1) Screenshot 2024-11-20 at 09 46 19 (1)

stupidly-logical commented 1 day ago

I'd like to work on this.

sreelakshmi-bruno commented 22 hours ago

Hi @fantpmas, thanks for reporting. I tried to run the bru file posted here, in the CLI and the assertions got passed. Not sure why this doesn't work on your side. Are you using the latest version of the cli (1.34.1)?

Screenshot 2024-11-21 at 11 10 43 AM
fantpmas commented 20 hours ago

Screenshot 2024-11-21 at 08 20 50 Ah weird, the cli version seems to be stuck on 1.11.0. Reinstalling does not help.

fantpmas commented 19 hours ago

Ah, totally forgot you have to install the CLI separately. 🤦 Updated to 1.34.1 and now it works indeed.