Skip to content

Commit 6096708

Browse files
Zie619claude
andcommitted
fix: update CTA test assertions and npm secret name
- Update test_cli.py: rename test and assert new CTA text - Fix publish-npm.yml: use NPM secret (not NPM_TOKEN) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent f95dff0 commit 6096708

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

.github/workflows/publish-npm.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,4 @@ jobs:
2828
- name: Publish to npm
2929
run: cd n8n-node && npm publish --access public
3030
env:
31-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
31+
NODE_AUTH_TOKEN: ${{ secrets.NPM }}

tests/test_cli.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -222,22 +222,22 @@ def test_no_color_env_var(monkeypatch):
222222
# The console.no_color flag should be set when NO_COLOR is present
223223

224224

225-
def test_scan_star_message_in_table_format():
226-
"""Test that star message appears in table format."""
225+
def test_scan_cta_message_in_table_format():
226+
"""Test that CTA message appears in table format."""
227227
demo_file = Path(__file__).parent.parent / "examples" / "demo-project" / "app.py"
228228
result = runner.invoke(app, ["scan", str(demo_file), "--format", "table"])
229229
assert result.exit_code == 0
230-
assert "Found ai-bom useful?" in result.output
231-
assert "https://github.com/Trusera/ai-bom" in result.output
230+
assert "info@trusera.dev" in result.output
231+
assert "trusera.dev" in result.output
232232

233233

234-
def test_scan_no_star_message_in_quiet_mode():
235-
"""Test that star message does not appear in quiet mode."""
234+
def test_scan_no_cta_message_in_quiet_mode():
235+
"""Test that CTA message does not appear in quiet mode."""
236236
demo_file = Path(__file__).parent.parent / "examples" / "demo-project" / "app.py"
237237
result = runner.invoke(app, ["scan", str(demo_file), "--quiet"])
238238
assert result.exit_code == 0
239-
# Quiet mode should suppress the star message
240-
assert "Found ai-bom useful?" not in result.output or "https://github.com" not in result.output
239+
# Quiet mode should suppress the CTA message
240+
assert "info@trusera.dev" not in result.output
241241

242242

243243
def test_scan_no_star_message_in_json_format():

0 commit comments

Comments
 (0)