Skip to content

Conversation

@peternhale
Copy link
Contributor

@peternhale peternhale commented Nov 6, 2025

Summary

Updates the README to document which environment variables are required and when they cause initialization errors. This improves developer experience by clearly indicating which environment variables must be set for different test scenarios.

Changes

  • Added a "Required?" column to the environment variables table
  • Added detailed usage notes explaining when each required variable is needed
  • Documented specific error conditions and when they occur
  • Added footnotes explaining conditional requirements vs. org authorization requirements

Required Environment Variables

The following environment variables are now clearly marked as required:

Conditionally Required (Yes*)

  • VSIX_TO_INSTALL - Required when installExtensions() is called
  • USE_EXISTING_PROJECT_PATH - Required when set (path must exist)
  • TEST_RESOURCES - Required when validateTestConfig() is called and neither testResources nor workspacePath is set

Required for Org Authorization (Yes**)

  • DEV_HUB_USER_NAME - Required when org authorization is needed
  • DEV_HUB_ALIAS_NAME - Required when org authorization is needed (has default but must match existing org)
  • SFDX_AUTH_URL - Required when authenticating with Salesforce (when no existing auth found)

Impact

This documentation update helps developers:

  • Understand which environment variables must be configured before running tests
  • Identify the root cause of initialization errors
  • Set up their test environment correctly from the start

Related

  • Work Item: @W-20148320@

@peternhale peternhale requested a review from madhur310 November 6, 2025 15:11
@peternhale peternhale changed the title fix: [W-20148320] update readme W-20148320: update readme Nov 6, 2025
This repository is published and used as an npm module, currently imported by `salesforcedx-vscode`. You can follow the same repository to see how this is utilized.

### Environment Variables

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't seem to add a comment on line 36, but since you are updating this - do you mind removing line: The full API documentation is available at [https://forcedotcom.github.io/salesforcedx-vscode-test-tools](https://forcedotcom.github.io/salesforcedx-vscode-test-tools). it wrong and the link doesn't work.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I made a suggestion for that heh

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.

4 participants