AnWeber / vscode-httpyac

Quickly and easily send REST, Soap, GraphQL, GRPC, MQTT and WebSocket requests directly within Visual Studio Code
https://marketplace.visualstudio.com/items?itemName=anweber.vscode-httpyac
MIT License
222 stars 20 forks source link

[BUG] Broken environment loading #230

Closed vojtech-pejsa-redbit closed 9 months ago

vojtech-pejsa-redbit commented 9 months ago

Version 6.7.0 broke environment loading when launching requests as tests, send action doesn't seem to be affected.

Steps to reproduce

1) Open file test.rest. 2) Click on action env: and select environment demo. 3) Click green triangle to run test. 4) Result is error: page is not defined

Action send works correctly with the same workflow.

Version 6.6.7 works without any problems.

Test files:

test.rest:

GET https://reqres.in/api/users?page={{page}}

httpyac.config.js:

module.exports = {
  environments: {
    demo: {
        page: 2
    }
  },
};
AnWeber commented 9 months ago

Unfortunately, I overlooked that this is the setting of testRunAlwaysUseEnv always truthy. I will correct it today.

vojtech-pejsa-redbit commented 9 months ago

Thank you for quick fix :slightly_smiling_face:.