Skip to content

ci: add GitHub Actions workflow #352

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

Open
wants to merge 15 commits into
base: master
Choose a base branch
from
Open

ci: add GitHub Actions workflow #352

wants to merge 15 commits into from

Conversation

TartanLeGrand
Copy link

@TartanLeGrand TartanLeGrand commented Apr 1, 2025

This pull request introduces a new GitHub Actions workflow to automate testing and code quality checks for the SDK. The workflow is triggered on pull requests and includes steps for dependency installation, environment preparation, building, formatting, linting, testing, and running SonarScanner for code quality analysis.

New GitHub Actions workflow:

  • .github/workflows/main.yml: Added a new workflow named "Test SDK" that runs on ubuntu-latest. It includes steps to:
    • Set up Node.js 18 and install dependencies.
    • Prepare a local test stack environment and build the project.
    • Check code formatting, lint the code, and run tests after installing global dependencies.
    • Perform code quality analysis using SonarScanner with relevant secrets and variables.

@TartanLeGrand TartanLeGrand marked this pull request as draft April 1, 2025 12:03
@TartanLeGrand TartanLeGrand marked this pull request as ready for review April 22, 2025 05:21
--health-retries 5

ipfs:
image: ipfs/go-ipfs:v0.9.1
Copy link
Author

Choose a reason for hiding this comment

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

Replace with kubo

SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }}

# Check for node 20 tests
Copy link
Author

Choose a reason for hiding this comment

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

EOL

env:
FORK_URL: ${{ steps.prepare.outputs.bellecour_url }}
FORK_BLOCK: ${{ steps.prepare.outputs.bellecour_block }}
command: >
Copy link
Author

Choose a reason for hiding this comment

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

Use options instead command

options: >-
--entrypoint bash
--mount type=bind,source=${{ github.workspace }}/local-stack-env,target=/local-stack-env
command: -c "export START_BLOCK=$(cat /local-stack-env/BELLECOUR_FORK_BLOCK) && cd /app && npm start"
Copy link
Author

Choose a reason for hiding this comment

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

Use options instead command

options: >-
--entrypoint bash
--mount type=bind,source=${{ github.workspace }}/local-stack-env,target=/local-stack-env
command: -c "export VOUCHER_HUB_START_BLOCK=$(cat /local-stack-env/BELLECOUR_FORK_BLOCK) && cd /iexec-voucher-subgraph && npm run all"
Copy link
Author

Choose a reason for hiding this comment

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

Use options instead command

TartanLeGrand and others added 10 commits June 10, 2025 10:05
* feat: add experimental networks default config

* test: reduce flakyness of tests based on RPC API providers

* test: add config module unit tests

* feat: add allowExperimentalNetworks option in chain.json

* feat: add allowExperimentalNetworks option in IExecConfig

* feat: add experimental network arbitrum-sepolia-testnet

* feat: add allowExperimentalNetworks in getSignerFromPrivateKey

* refactor: move defaults hub address in config

* docs: update comment

Co-authored-by: Robin Le Caignec <[email protected]>

* refactor: networks are not considered experimental by default

* fix: prevent unneeded errors when voucher is not deployed but not used

---------

Co-authored-by: Robin Le Caignec <[email protected]>
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.

2 participants