summaryrefslogtreecommitdiff
path: root/web/test
diff options
context:
space:
mode:
authorPeter Stone <thepeterstone@gmail.com>2026-03-13 05:24:20 +0000
committerPeter Stone <thepeterstone@gmail.com>2026-03-13 05:24:20 +0000
commitfb0e4b44393bae3c54f099bea87dfea19854d058 (patch)
tree4c3112f2a05ee91773c5d045207a11a85c72f8e2 /web/test
parentfe414fac958330c2302d9175d66e1b338e5b1864 (diff)
fix: enable Gemini file writing by passing --yolo and -p flags
GeminiRunner.buildArgs was missing --yolo (auto-approve all tools) so the gemini CLI only registered 3 tools (read_file, write_todos, cli_help) and write_file was not available. Agents that needed to create files silently failed (exit 0, no files written). Also switch instructions from bare positional arg to -p flag, which is required for non-interactive headless mode. Update preamble tests to match file-based summary approach (CLAUDOMATOR_SUMMARY_FILE) kept from the merge conflict resolution. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'web/test')
-rw-r--r--web/test/new-task-button.test.mjs24
1 files changed, 24 insertions, 0 deletions
diff --git a/web/test/new-task-button.test.mjs b/web/test/new-task-button.test.mjs
new file mode 100644
index 0000000..45a3548
--- /dev/null
+++ b/web/test/new-task-button.test.mjs
@@ -0,0 +1,24 @@
+// new-task-button.test.mjs — visibility contract for the New Task button
+//
+// The New Task button lives in the global header and must be visible on all tabs.
+// Run with: node --test web/test/new-task-button.test.mjs
+
+import { describe, it } from 'node:test';
+import assert from 'node:assert/strict';
+import { newTaskButtonShouldShowOnTab } from '../app.js';
+
+const ALL_TABS = ['tasks', 'active', 'running', 'stats'];
+
+describe('new task button visibility', () => {
+ for (const tab of ALL_TABS) {
+ it(`is visible on "${tab}" tab`, () => {
+ assert.equal(newTaskButtonShouldShowOnTab(tab), true, `expected button to be visible on tab "${tab}"`);
+ });
+ }
+
+ it('is visible on any unknown future tab', () => {
+ assert.equal(newTaskButtonShouldShowOnTab('help'), true);
+ assert.equal(newTaskButtonShouldShowOnTab('templates'), true);
+ assert.equal(newTaskButtonShouldShowOnTab(''), true);
+ });
+});