Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide standard PIO* and PLATFORMIO_* environment variables when running test command #4882

Open
1 task done
nomis opened this issue Mar 24, 2024 · 1 comment
Open
1 task done

Comments

@nomis
Copy link
Contributor

nomis commented Mar 24, 2024

What kind of issue is this?

  • Feature Request.
    Start by telling us what problem you’re trying to solve. Often a solution
    already exists! Don’t send pull requests to implement new features without first getting our
    support. Sometimes we leave features out on purpose to keep the project small.

Configuration

PlatformIO Version (platformio --version): 6.1.14

Description of problem

Making a custom wrapper around test_testing_command is inconvenient because PlatformIO core has access to information that variables do not, like the current environment name (not just the section name) and the program name (which isn't program on Windows).

If the test command was executed with the PIOENV environment variable then a script would know what the current environment is. An additional variable could contain the program name (although any script is unlikely to work on both Windows and non-Windows environments).

@nomis
Copy link
Contributor Author

nomis commented Mar 24, 2024

I expect this isn't trivial to do for all the environment variables because the test runner doesn't have them because it's a separate process, but it does know the PIO environment name and the program name which would be very useful for any wrapper script.

nomis added a commit to nomis/mcu-app that referenced this issue Mar 24, 2024
@ivankravets ivankravets added this to the 7.0 milestone Mar 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants