bruno icon indicating copy to clipboard operation
bruno copied to clipboard

Vars defined on request level returns with different datatype in Safe and Dev mode

Open SPIRIT-00 opened this issue 1 year ago • 0 comments

I have checked the following:

  • [X] I use the newest version of bruno.
  • [X] I've searched existing issues and found nothing related to my issue.

Describe the bug

null and boolean values return as string in safe mode.

Unexpected behavior, it may cause incorrect scripts work.

.bru file to reproduce the bug

meta { name: DataType type: http seq: 1 }

get { url: {{TestServerApi}} body: json auth: none }

auth:basic { username: password: }

auth:bearer { token: }

vars:pre-request { BooleanVar: false StringVar: testString NullVar: null NumberVar1: 1 NumberVar2: 0 NumberVar3: -1 }

assert { BooleanVar: isBoolean StringVar: isString NullVar: isNull NumberVar1: isNumber NumberVar2: isNumber NumberVar3: isNumber }

Screenshots/Live demo link

Define request level vars: изображение

Safe mode: изображение

Dev mode: изображение

SPIRIT-00 avatar Aug 23 '24 16:08 SPIRIT-00