summaryrefslogtreecommitdiff
path: root/cli/tests/test_cli_backtest.py
diff options
context:
space:
mode:
authorTheSiahxyz <164138827+TheSiahxyz@users.noreply.github.com>2026-04-01 17:56:16 +0900
committerTheSiahxyz <164138827+TheSiahxyz@users.noreply.github.com>2026-04-01 17:56:16 +0900
commitfa7e1dc44787592da647bdda0a63310be0cfcc8b (patch)
tree9533c747f8a40aaa1697252382bfbbafc8f3fe9d /cli/tests/test_cli_backtest.py
parenta65575124b18f2ec5d418623e22c5bdef6c3424e (diff)
test: add CLI command tests and API router tests
Diffstat (limited to 'cli/tests/test_cli_backtest.py')
-rw-r--r--cli/tests/test_cli_backtest.py19
1 files changed, 19 insertions, 0 deletions
diff --git a/cli/tests/test_cli_backtest.py b/cli/tests/test_cli_backtest.py
new file mode 100644
index 0000000..84227a9
--- /dev/null
+++ b/cli/tests/test_cli_backtest.py
@@ -0,0 +1,19 @@
+"""Tests for backtest CLI commands."""
+from click.testing import CliRunner
+from trading_cli.main import cli
+
+
+def test_backtest_run_help():
+ runner = CliRunner()
+ result = runner.invoke(cli, ["backtest", "run", "--help"])
+ assert result.exit_code == 0
+ assert "--strategy" in result.output
+ assert "--symbol" in result.output
+ assert "--balance" in result.output
+
+
+def test_backtest_report_help():
+ runner = CliRunner()
+ result = runner.invoke(cli, ["backtest", "report", "--help"])
+ assert result.exit_code == 0
+ assert "--id" in result.output