Skip to content

Custom variable not being evaluated when defined in the same request #508

@camilamaia

Description

@camilamaia

Bug report

Environment

ScanAPI version: 2.6.0

Description of the bug

When the custom var is defined and used in the same request, it is not being evaluated.

How to reproduce the bug ?

endpoints:
  - name: snippets-api
    path: http://demo.scanapi.dev/api/v1/
    headers:
      Content-Type: application/json
    requests:
      - name: health
        vars:
          my_var: "one"
        path: health/?${my_var}

image

Expected behavior?

image

Anything else we need to know?

It works for env variables. The problem appears only for custom vars

Metadata

Metadata

Assignees

Labels

BugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions