1
0
mirror of https://github.com/ycd/manage-fastapi.git synced 2021-11-08 01:34:39 +03:00

💡 Change the name of interact command

This commit is contained in:
yagiz
2020-12-07 21:58:03 +03:00
committed by Yağızcan Değirmenci
parent 65747d50d1
commit 8ece434644
2 changed files with 3 additions and 3 deletions

View File

@@ -20,7 +20,7 @@ app = typer.Typer(
@app.command(help="Creates a FastAPI project.")
def startproject(
name: str,
interact: bool = typer.Option(False),
interactive: bool = typer.Option(False, help="Run in interactive mode."),
database: Optional[Database] = typer.Option(None, case_sensitive=False),
docker: bool = typer.Option(False),
license_: Optional[License] = typer.Option(None, "--license", case_sensitive=False),
@@ -28,7 +28,7 @@ def startproject(
pre_commit: bool = typer.Option(False, "--pre-commit"),
python: PythonVersion = typer.Option(PythonVersion.THREE_DOT_EIG),
):
if interact:
if interactive:
result = launch_cli(
("packaging", bullet(PackageManager)),
("python", bullet(PythonVersion)),

View File

@@ -40,7 +40,7 @@ def test_startproject(
}
mock_obj.side_effect = side_effect
result = runner.invoke(app, ["startproject", project_name, "--interact"])
result = runner.invoke(app, ["startproject", project_name, "--interactive"])
assert mock_obj.assert_called_once
assert result.output == CREATED_SUCCESSFULLY
assert result.exit_code == 0