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

test: e2e subnets subcommand #1948

Open
wants to merge 1 commit into
base: staging
Choose a base branch
from
Open

test: e2e subnets subcommand #1948

wants to merge 1 commit into from

Conversation

orriin
Copy link
Contributor

@orriin orriin commented May 29, 2024

Adds e2e tests for subnets subcommands.

exec_command(RegisterSubnetworkCommand, ["subnet", "create"])
exec_command(RegisterCommand, ["subnet", "register", "--netuid", "1"])
exec_command(
SubnetHyperparamsCommand, ["subnet", "hyperparameters", "--netuid", "1"]
Copy link
Contributor

Choose a reason for hiding this comment

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

We should be asserts each of these commands

# Can call after adding a subnet
exec_command(RootRegisterCommand, ["root", "register"])
exec_command(RegisterSubnetworkCommand, ["subnet", "create"])
exec_command(SubnetListCommand, ["subnet", "list"])
Copy link
Contributor

Choose a reason for hiding this comment

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

In addition to assert these command , I think it might be a good idea to use capsys to assert the stdout . See example by Greg

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants