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

Add a scripts folder in root with bash script that can run a local testnet #11

Conversation

marc-aurele-besner
Copy link
Collaborator

Add a scripts folder in root with bash script that can run a local testnet

Hopefully, this will make the development easier, especially as we start tackling extrinsics

Localhost testing

To test the packages against a local node, you can use the script at scripts/localhost.sh.

  1. Verify that the line 3-7 of the script matches your current OS and architecture.

    # Change the following variables as needed
    # OS to download
    OS="macos" # macos | ubuntu | windows
    # Architecture to download
    ARCHITECTURE="aarch64" # aarch64 | x86_64-skylake | x86_64-v2
  2. Run the script:

    ./scripts/localhost.sh

    This script will download the latest version of the node and farmer for your OS and architecture, start the node, and farmer

  3. Run the tests:

    bash scripts/localhost-run-test.sh

    The tests will detect the local node and farmer and run the tests against them instead of the public testnet.

Copy link
Member

@jfrank-summit jfrank-summit left a comment

Choose a reason for hiding this comment

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

Looks great! This will work well for consensus, we may want to add support for auto-id in the future as well.

@marc-aurele-besner
Copy link
Collaborator Author

Looks great! This will work well for consensus, we may want to add support for auto-id in the future as well.

Indeed, I was just not to sure how to go about run an operator in localhost :)

@marc-aurele-besner marc-aurele-besner merged commit 01b0701 into main Jun 4, 2024
3 checks passed
@marc-aurele-besner marc-aurele-besner deleted the 8-add-a-scripts-folder-in-root-with-bash-script-that-can-run-a-local-testnet branch June 4, 2024 22:48
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.

Add a scripts folder in root with bash script that can run a local testnet
2 participants