Skip to content

Conversation

@shreyb
Copy link
Collaborator

@shreyb shreyb commented Sep 3, 2025

Closes #99

Adds a new flag, -s/--server, that allows for users to override the configured api.base_url value. This allows for quick testing of different FERRY instances.

Also added unit tests for both the changed functionality in the FerryCLI class, and the overall CLI and new flag.

All unit tests pass, as well as the following check:

$ ./bin/ferry-cli --dryrun --server https://fakeserver:12345  -e ping

Would call endpoint: https://fakeserver:12345/ping with params
{}

@shreyb shreyb requested a review from Copilot September 3, 2025 18:56
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR adds a new command-line flag -s/--server that allows users to override the configured api.base_url value for quick testing of different FERRY instances.

  • Adds server flag to auth parser with help text
  • Modifies FerryCLI constructor to accept optional base_url parameter
  • Updates main function to pass server flag value to FerryCLI constructor
  • Adds comprehensive unit tests for both FerryCLI class and CLI functionality
  • Refactors existing test to use parametrized approach

Reviewed Changes

Copilot reviewed 3 out of 4 changed files in this pull request and generated no comments.

File Description
ferry_cli/helpers/auth.py Adds the new -s/--server argument to the auth parser
ferry_cli/main.py Updates FerryCLI constructor to accept base_url parameter and modifies main function to pass server flag
tests/test_main.py Adds unit tests for server flag functionality and refactors existing test to use pytest parametrize

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@shreyb shreyb requested a review from LTrestka September 3, 2025 18:56
@LTrestka LTrestka merged commit e1b4f40 into master Sep 16, 2025
1 check passed
@LTrestka LTrestka deleted the issue-99 branch September 16, 2025 17:13
@shreyb shreyb added this to the 1.1.0 milestone Oct 13, 2025
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 ferry server override flag

3 participants