codeburn/mac/Tests/CodeBurnMenubarTests
Resham Joshi 57aa744343
feat(menubar): ask for a GitHub star once after the third open (#1827)
This mirrors #1826 for the macOS menubar app. From the third time the popover opens, a small card asks for a GitHub star with the same copy as the desktop: Enjoying CodeBurn?, one muted line saying a star would mean a lot and keeps the project free and open, and Not now and Star on GitHub buttons, with Star on GitHub as the default action.

The menubar already had a one-line star strip at the bottom of the popover, shown from the very first launch with an X to hide it. This replaces that strip in the same slot and the same tinted style as the update banner above it, so there is still only one star ask. There is no GitHub mark in the menubar bundle, so the card has no mark, and the old SF Symbol star is gone.

Opens are counted in UserDefaults under codeburn.starNudgeOpens, counted in the click handler that shows the popover. Either button sets codeburn.starNudgeDone and removes the card at once; closing the popover without pressing a button leaves no flag, so it shows again on the next open. Anyone who already closed the old strip (codeburn.starBannerDismissed) is not asked again. Nothing checks whether a star was given. The strings are in all six catalogs, using the same translations as the desktop, and the two strings only the old strip used are removed.

Verified with xcrun swiftc -typecheck over the whole module and over the new StarNudgeTests together with the module, both clean. The new test and the full suite were not run locally; macOS Menubar CI runs swift build, swift test (including the localization catalog and coverage checks) and the packaging script on this PR. Not checked in a running app yet.
2026-11-02 15:46:37 +01:00
..
AgentTabProviderVisibilityTests.swift fix(menubar,app): absent hasUsage hid every provider with no period spend 2026-09-02 07:32:02 -07:00
AntigravityQuotaPresentationTests.swift feat(menubar): live Antigravity quota — local language-server probe, Settings pane, Plan tab 2026-08-24 09:40:04 -07:00
AntigravityQuotaTests.swift feat: Google AI plan presets and the Antigravity tier label (#1683) 2026-10-07 23:34:49 +02:00
AppStoreCopilotDisconnectTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
AppStoreRefreshConcurrencyTests.swift fix(menubar): a twice-contradicting scoped payload threw instead of being served 2026-09-02 07:54:55 -07:00
AppStoreRefreshRecoveryTests.swift fix(menubar): the selection fallback showed another provider's totals under the selected tab 2026-09-02 07:55:43 -07:00
AppVersionTests.swift Normalize menubar version display 2026-05-11 11:21:39 -07:00
CapacityDockConnectionActionTests.swift feat(quota): Command Code quota and ClinePass from the Cline sign-in (#1682) 2026-10-07 23:34:31 +02:00
CapacityDockGlanceTests.swift fix(menubar): record Codex early resets at 0% and stop reconnect text clipping at 0.9 dock scale (#1490) 2026-09-18 15:09:37 -07:00
CapacityDockGlanceWindowTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
CapacityDockInteractionStateTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
CapacityDockMotionTests.swift feat(menubar): add native Capacity Dock (#1167) 2026-08-29 00:37:30 -07:00
CapacityDockPlacementTests.swift fix(menubar): keep Capacity Dock hover alive after app deactivation (#1170) 2026-08-29 18:42:27 +02:00
CapacityDockPointerUpdateCoalescerTests.swift Fix Capacity Dock pointer coalescing and dismissal 2026-09-01 16:51:00 +05:30
CapacityDockPreferencesTests.swift fix(menubar): check a provider when its settings open, keep the dock order (#1735) 2026-10-10 21:40:47 +02:00
CapacityDockPresentationTests.swift feat(quota): Command Code quota and ClinePass from the Cline sign-in (#1682) 2026-10-07 23:34:31 +02:00
CapacityDockProviderQuotaServiceTests.swift fix(quota): say when Cline's saved login expired and how to renew it (#1736) 2026-10-10 21:40:52 +02:00
CapacityDockTodayTests.swift menubar: size and pad the Capacity Dock glance popover (#1470) 2026-09-17 16:57:39 +02:00
CapacityEstimatorTests.swift feat(mac): native Swift menubar app + one-command install 2026-04-17 16:55:56 -07:00
ClaudeRateLimitTests.swift menubar: honor Retry-After on Claude quota 429s, back off failed refreshes (#702) 2026-07-16 14:52:47 -07:00
ClaudeSubscriptionParsingTests.swift Claude plan label: read subscriptionType so a Team seat is not shown as Max 5x (#1492) 2026-09-19 11:25:17 -07:00
ClinePassQuotaTests.swift fix(quota): say when Cline's saved login expired and how to renew it (#1736) 2026-10-10 21:40:52 +02:00
CLIWatchdogTests.swift 0.9.25: correctness, energy, menu bar and installer fixes (#1511) 2026-09-21 00:16:21 +02:00
CodeBurnCacheDirectoryTests.swift perf(desktop): share cache state and eliminate duplicate cold hydration 2026-08-12 17:16:41 +03:00
CodeburnCLIPathTests.swift fix(mac): prefer the node beside the CLI over a version manager's default 2026-09-07 10:16:48 +08:00
CodexBankedResetTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
CodexPlanParsingTests.swift feat(codex): show the credit limit on credit-metered ChatGPT workspaces 2026-07-27 08:19:59 -04:00
CodexQuotaSummaryTests.swift fix(codex): align credit/dollar footer formatting across desktop and menubar 2026-08-01 22:32:53 +02:00
CodexResetCreditsTests.swift feat(codex): read the per-credit fields the reset-credits payload already carries 2026-09-12 14:37:24 -07:00
CodexTerminalFailureTests.swift test(menubar): lock in Codex terminal-failure classification 2026-05-30 12:32:19 -07:00
CommandCodeQuotaTests.swift fix(commandcode): show the monthly window (#1734) 2026-10-10 21:40:43 +02:00
ContributionHeatmapTests.swift fix(menubar-tests): add missing localModelSavings/savingsUSD args so swift tests compile (#465) 2026-06-09 21:56:13 +02:00
CopilotHostEndpointTests.swift fix(menubar): give the pasted Copilot token a GitHub host of its own 2026-09-12 12:02:13 -07:00
CopilotQuotaPresentationTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
CopilotQuotaTests.swift fix(menubar): give the pasted Copilot token a GitHub host of its own 2026-09-12 12:02:13 -07:00
CredentialKeychainCacheRedTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
CredentialKeychainContinuityTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
CursorQuotaTests.swift fix(cursor): unwrap Cursor 3.27 safe-storage sessions (#1802) 2026-10-30 22:32:51 +01:00
CursorSyncStatusTests.swift feat(cursor): show the Cursor sync status and an on/off switch in the apps (#1638) 2026-10-05 17:11:41 +02:00
DataClientProcessTests.swift fix(menubar): no-output watchdog, lock signal cleanup, dead-pid takeover, serve orphan reaping 2026-08-23 05:35:17 -07:00
DefaultsKeyObserverTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
DevinQuotaTests.swift feat(devin): plan and quota from the Devin CLI cache (#1606) 2026-10-02 16:43:15 +02:00
EarlyQuotaResetTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
GeminiQuotaTests.swift test(menubar): align Gemini retired-tier expectation with the em-dash-free message 2026-08-24 10:08:33 -07:00
GrokBotSubscriptionServiceTests.swift Grok Bot: sessions, estimated spend and the weekly allowance on all three surfaces (#1462) 2026-09-16 21:17:48 +02:00
GrokBuildSubscriptionServiceTests.swift fix(mac): treat omitted Grok credit percent as 0% in an active window 2026-09-02 15:06:17 -07:00
KimiQuotaPresentationTests.swift fix(menubar): keep showing Kimi quota when the login is idle, stamp stale data 2026-07-26 06:35:13 -07:00
KimiUsageParsingTests.swift menubar: add Kimi Code subscription quota tracking 2026-07-23 21:31:55 +02:00
LanguagePreferenceTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
LiveKeychainCredentialCacheTests.swift 0.9.25: correctness, energy, menu bar and installer fixes (#1511) 2026-09-21 00:16:21 +02:00
LocalizationCatalogTests.swift desktop and menu bar: six-language localization (#1493) 2026-09-19 03:25:46 -07:00
LocalizationCoverageTests.swift fix(menubar): pin multi-argument catalog keys to positional specifiers 2026-09-15 01:33:28 +03:00
LocalizationSourceScanner.swift fix(menubar): pin multi-argument catalog keys to positional specifiers 2026-09-15 01:33:28 +03:00
LocalizationSwitchTests.swift 0.9.25 round 2: fixes found testing the built apps (#1517) 2026-09-21 13:53:45 +02:00
MenubarPayloadCombinedTests.swift fix(usage): preserve project identity and qualify incomplete session counts 2026-09-07 22:02:54 +05:30
MenubarPeriodSettingsTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
MenubarRemoteCommandTests.swift 0.9.25 round 2: fixes found testing the built apps (#1517) 2026-09-21 13:53:45 +02:00
MenubarSecondRowTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
MenubarStatusCacheTests.swift feat(menubar): add Local/Combined usage toggle (#566) (#568) 2026-06-28 22:01:01 +02:00
ModelEntryTokenCountsTests.swift feat: mark estimated dollars the same way in every view (#1657) 2026-10-06 22:27:13 +02:00
ModelsSectionTokenLineTests.swift fix: uncap the Overview model table, billions token rung, unpriced calls dimming (#1443) 2026-09-17 13:53:10 +02:00
ModelsSectionUnpricedLineTests.swift fix: name the usage that prices at $0 instead of hiding it (#1491) 2026-09-18 16:48:26 -07:00
ProviderConnectionCatalogTests.swift feat(quota): Command Code quota and ClinePass from the Cline sign-in (#1682) 2026-10-07 23:34:31 +02:00
ProviderIconTests.swift feat(menubar): add native Capacity Dock (#1167) 2026-08-29 00:37:30 -07:00
ProviderReconnectPresentationTests.swift fix menubar provider usage contracts 2026-09-02 16:17:28 +05:30
ProviderSettingsEditorStateTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
ProviderStripPagingStateTests.swift harden provider period and cache contracts 2026-09-02 16:18:05 +05:30
QuotaCrossingTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
QuotaFreshnessTests.swift fix(menubar): stop the dock resizing and claiming a refresh it is not doing 2026-09-12 12:19:29 -07:00
QuotaPaceTests.swift menubar: linear pace on Codex quota windows — deficit/reserve, projection, run-out ETA (#726) (#728) 2026-07-20 05:21:43 -07:00
QuotaRefreshDecisionTests.swift Force a quota refresh when a window rolls over 2026-09-13 13:49:46 -07:00
QuotaSummaryHeadlineTests.swift menubar: one set of quota colour bands, 60/70/95, for the flame, popover and dock 2026-09-13 12:50:25 -07:00
QuotaWarningRowTests.swift test(menubar): spell the 2d 3h 5m offset as one literal so Swift 6.2 can type-check it 2026-09-13 06:30:25 -07:00
RefreshCadenceTests.swift menubar: skip unchanged background refreshes, 120s AC idle cadence, utility QoS for tick spawns (#703) (#704) 2026-07-16 15:11:25 -07:00
ServeConnectionTests.swift 0.9.25: correctness, energy, menu bar and installer fixes (#1511) 2026-09-21 00:16:21 +02:00
SessionCountLabelTests.swift fix(usage): fold Windows case in spend identity, qualify --json counts, drop scratch tests 2026-09-07 14:56:32 -07:00
SessionFocusTests.swift fix: stop a stuck cursor, pick the right Claude session file, skip the Kimi blob walk 2026-09-14 03:42:39 -07:00
SettingsWindowPlacementTests.swift 0.9.25 round 2: fixes found testing the built apps (#1517) 2026-09-21 13:53:45 +02:00
SingleInstanceGuardTests.swift 0.9.25: correctness, energy, menu bar and installer fixes (#1511) 2026-09-21 00:16:21 +02:00
StarNudgeTests.swift feat(menubar): ask for a GitHub star once after the third open (#1827) 2026-11-02 15:46:37 +01:00
StatusItemContextMenuPolicyTests.swift test(mac): lock status-item context menu policy (#802) 2026-07-24 19:27:25 +07:00
StatusItemPlacementPolicyTests.swift menubar: keep retrying parked status item on a persistent menu bar (#1461) 2026-09-16 18:46:13 +02:00
TelemetryTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
TerminalLauncherTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
TestDefaults.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
TrendMetricTests.swift feat(menubar): Cost/Tokens toggle on the Trend chart, Cost by default (#1603) 2026-10-02 11:18:57 +02:00
UpdateCheckerTests.swift feat(update): menubar pill checks and updates through the engine (#1742) 2026-10-11 04:35:30 +02:00
UpdateNotificationTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
UsageDataChangeGuardTests.swift feat: Amp support - read the local thread mirror (#1572) (#1578) 2026-10-02 10:36:05 +02:00
UserDefaultsSuiteLeakGuardTests.swift test(mac): fixed names for scratch settings suites (#1576) 2026-10-02 16:18:38 +02:00
ZaiQuotaTests.swift feat(quota): add ZCode (z.ai coding plan) live quota provider (#1347) 2026-09-18 18:11:08 -07:00
ZcodeQuotaTests.swift feat(quota): add ZCode (z.ai coding plan) live quota provider (#1347) 2026-09-18 18:11:08 -07:00