Skip to content

Comments

Fix access to the GITHUB_TOKEN#174

Merged
asgrim merged 3 commits intophp:mainfrom
Bellangelo:use-gh-token-when-running-test-suite
Jan 14, 2025
Merged

Fix access to the GITHUB_TOKEN#174
asgrim merged 3 commits intophp:mainfrom
Bellangelo:use-gh-token-when-running-test-suite

Conversation

@Bellangelo
Copy link
Contributor

@Bellangelo Bellangelo commented Jan 10, 2025

Closes #169

The main issue was that while this test was trying to use the GITHUB_TOKEN environment variable, the variable was scoped to be used in a specific command only. I moved the env to the top so it can be accessed by all the commands in the step.

Furthermore, this line - run: composer config --global github-oauth.github.com ${{ secrets.GITHUB_TOKEN }} is removed because this is handled by the setup-php action. For references please check https://github.com/shivammathur/setup-php/blob/main/src/scripts/tools/add_tools.sh#L64 and https://github.com/shivammathur/setup-php?tab=readme-ov-file#wrench-tools-support

@asgrim asgrim self-assigned this Jan 14, 2025
@asgrim asgrim added the bug Something isn't working label Jan 14, 2025
@asgrim asgrim added this to the 0.6.0 milestone Jan 14, 2025
@asgrim
Copy link
Contributor

asgrim commented Jan 14, 2025

Thanks @Bellangelo !

@asgrim asgrim merged commit 286930c into php:main Jan 14, 2025
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Pass the GH token to tests

2 participants