Repository navigation
Test unsubscribed local credit purchase flow - #15797
Conversation
Amp-Thread-ID: https://ampcode.com/threads/T-01a03446-3607-720c-bc68-d27f31e10438 Co-authored-by: Amp <amp@ampcode.com>
🎭 Playwright: ✅ 1993 passed, 0 failed · 1 flaky📊 Browser Reports
📦 Bundle: 9.14 MB gzip ⚪ 0 BDetailsSummary
Category Glance App Entry Points — 3.71 kB (baseline 3.71 kB) • ⚪ 0 BMain entry bundles and manifests Status: 1 unchanged Graph Workspace — 1.4 MB (baseline 1.4 MB) • ⚪ 0 BGraph editor runtime, canvas, workflow orchestration Status: 3 unchanged Views & Navigation — 124 kB (baseline 124 kB) • ⚪ 0 BTop-level views, pages, and routed surfaces Status: 17 unchanged Panels & Settings — 591 kB (baseline 591 kB) • ⚪ 0 BConfiguration panels, inspectors, and settings screens Status: 27 unchanged User & Accounts — 27.5 kB (baseline 27.5 kB) • ⚪ 0 BAuthentication, profile, and account management bundles Status: 11 unchanged Editors & Dialogs — 125 kB (baseline 125 kB) • ⚪ 0 BModals, dialogs, drawers, and in-app editors Status: 8 unchanged UI Components — 112 kB (baseline 112 kB) • ⚪ 0 BReusable component library chunks Status: 15 unchanged Data & Services — 3.46 MB (baseline 3.46 MB) • ⚪ 0 BStores, services, APIs, and repositories Status: 17 unchanged Utilities & Hooks — 549 kB (baseline 549 kB) • ⚪ 0 BHelpers, composables, and utility bundles Status: 37 unchanged Vendor & Third-Party — 18.1 MB (baseline 18.1 MB) • ⚪ 0 BExternal libraries and shared vendor chunks Status: 18 unchanged Other — 14.3 MB (baseline 14.3 MB) • ⚪ 0 BBundles that do not match a named category Status: 290 unchanged ⚡ Performance Report
Show regressions
All metrics
Historical variance (last 15 runs)
Trend (last 15 commits on main)
Raw data{
"timestamp": "2026-08-24T18:09:08.695Z",
"gitSha": "6551a40d22dd9d279b0f22eee770593dd25f4341",
"branch": "test/unsubscribed-local-credit-purchase",
"measurements": [
{
"name": "canvas-idle",
"durationMs": 2068.025000000034,
"styleRecalcs": 7,
"styleRecalcDurationMs": 5.922000000000001,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 525.544,
"heapDeltaBytes": 13001180,
"heapUsedBytes": 82153228,
"domNodes": -282,
"jsHeapTotalBytes": 5234688,
"scriptDurationMs": 9.974,
"eventListeners": -155,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "canvas-idle",
"durationMs": 2063.297999999918,
"styleRecalcs": 8,
"styleRecalcDurationMs": 7.891000000000002,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 510.7699999999999,
"heapDeltaBytes": 1360072,
"heapUsedBytes": 70399444,
"domNodes": -282,
"jsHeapTotalBytes": 4710400,
"scriptDurationMs": 8.715000000000002,
"eventListeners": -185,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "canvas-mouse-sweep",
"durationMs": 2350.265000000036,
"styleRecalcs": 78,
"styleRecalcDurationMs": 43.059,
"layouts": 12,
"layoutDurationMs": 3.972,
"taskDurationMs": 1429.01,
"heapDeltaBytes": 20821576,
"heapUsedBytes": 83113780,
"domNodes": -281,
"jsHeapTotalBytes": 5758976,
"scriptDurationMs": 170.77800000000002,
"eventListeners": -187,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "canvas-mouse-sweep",
"durationMs": 2192.5979999999754,
"styleRecalcs": 79,
"styleRecalcDurationMs": 42.714999999999996,
"layouts": 12,
"layoutDurationMs": 3.718,
"taskDurationMs": 1233.884,
"heapDeltaBytes": -242572,
"heapUsedBytes": 69257412,
"domNodes": -281,
"jsHeapTotalBytes": 5496832,
"scriptDurationMs": 155.372,
"eventListeners": -155,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "canvas-zoom-sweep",
"durationMs": 1713.499000000013,
"styleRecalcs": 31,
"styleRecalcDurationMs": 15.313,
"layouts": 6,
"layoutDurationMs": 0.715,
"taskDurationMs": 365.6090000000001,
"heapDeltaBytes": 3151720,
"heapUsedBytes": 65274960,
"domNodes": 74,
"jsHeapTotalBytes": 4718592,
"scriptDurationMs": 11.709999999999997,
"eventListeners": 19,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "canvas-zoom-sweep",
"durationMs": 1771.8439999999873,
"styleRecalcs": 31,
"styleRecalcDurationMs": 22.485000000000003,
"layouts": 6,
"layoutDurationMs": 0.669,
"taskDurationMs": 412.64500000000004,
"heapDeltaBytes": 4330596,
"heapUsedBytes": 73780596,
"domNodes": 76,
"jsHeapTotalBytes": 5242880,
"scriptDurationMs": 13.497000000000002,
"eventListeners": 19,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "dom-widget-clipping",
"durationMs": 706.3850000000116,
"styleRecalcs": 10,
"styleRecalcDurationMs": 6.088000000000001,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 418.77200000000005,
"heapDeltaBytes": -6063736,
"heapUsedBytes": 63417632,
"domNodes": 16,
"jsHeapTotalBytes": 5505024,
"scriptDurationMs": 31.970000000000006,
"eventListeners": 0,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "dom-widget-clipping",
"durationMs": 722.3960000000034,
"styleRecalcs": 9,
"styleRecalcDurationMs": 6.061999999999999,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 422.48599999999993,
"heapDeltaBytes": -5964988,
"heapUsedBytes": 64014672,
"domNodes": 14,
"jsHeapTotalBytes": 5767168,
"scriptDurationMs": 32.512,
"eventListeners": 2,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333332,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "large-graph-idle",
"durationMs": 2053.094999999985,
"styleRecalcs": 4,
"styleRecalcDurationMs": 3.5949999999999975,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 616.273,
"heapDeltaBytes": -17634020,
"heapUsedBytes": 73471764,
"domNodes": -271,
"jsHeapTotalBytes": -1576960,
"scriptDurationMs": 41.94799999999999,
"eventListeners": -155,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-idle",
"durationMs": 2054.9650000000383,
"styleRecalcs": 4,
"styleRecalcDurationMs": 9.812999999999999,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 610.508,
"heapDeltaBytes": -18837744,
"heapUsedBytes": 72659204,
"domNodes": -273,
"jsHeapTotalBytes": -1052672,
"scriptDurationMs": 41.775,
"eventListeners": -153,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-pan",
"durationMs": 3198.0890000000386,
"styleRecalcs": 62,
"styleRecalcDurationMs": 9.067000000000002,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 2565.639,
"heapDeltaBytes": 25608252,
"heapUsedBytes": 90357984,
"domNodes": 0,
"jsHeapTotalBytes": 487424,
"scriptDurationMs": 903.756,
"eventListeners": 8,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-pan",
"durationMs": 3232.821000000058,
"styleRecalcs": 63,
"styleRecalcDurationMs": 10.205000000000002,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 2566.8990000000003,
"heapDeltaBytes": 26185108,
"heapUsedBytes": 90706848,
"domNodes": 2,
"jsHeapTotalBytes": 487424,
"scriptDurationMs": 912.7330000000001,
"eventListeners": 8,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "large-graph-zoom",
"durationMs": 4433.393999999964,
"styleRecalcs": 66,
"styleRecalcDurationMs": 12.53,
"layouts": 60,
"layoutDurationMs": 8.406,
"taskDurationMs": 2648.349,
"heapDeltaBytes": 519252,
"heapUsedBytes": 72652952,
"domNodes": -265,
"jsHeapTotalBytes": -1351680,
"scriptDurationMs": 894.582,
"eventListeners": -177,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "large-graph-zoom",
"durationMs": 4325.197000000003,
"styleRecalcs": 67,
"styleRecalcDurationMs": 13.366,
"layouts": 60,
"layoutDurationMs": 8.055,
"taskDurationMs": 2579.012,
"heapDeltaBytes": -4430864,
"heapUsedBytes": 67589052,
"domNodes": -234,
"jsHeapTotalBytes": -303104,
"scriptDurationMs": 887.8439999999999,
"eventListeners": -149,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "legacy-node-drag",
"durationMs": 3262.5980000000254,
"styleRecalcs": 41,
"styleRecalcDurationMs": 5.512000000000003,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 2098.63,
"heapDeltaBytes": 13287320,
"heapUsedBytes": 79852508,
"domNodes": 0,
"jsHeapTotalBytes": 942080,
"scriptDurationMs": 208.55499999999998,
"eventListeners": 188,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "legacy-node-drag",
"durationMs": 3233.1429999999273,
"styleRecalcs": 41,
"styleRecalcDurationMs": 5.644,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 2139.03,
"heapDeltaBytes": -4648336,
"heapUsedBytes": 67663528,
"domNodes": -288,
"jsHeapTotalBytes": -827392,
"scriptDurationMs": 211.527,
"eventListeners": -1,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "minimap-idle",
"durationMs": 2044.2630000000008,
"styleRecalcs": 3,
"styleRecalcDurationMs": 2.9990000000000014,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 580.01,
"heapDeltaBytes": -22224240,
"heapUsedBytes": 72337328,
"domNodes": -276,
"jsHeapTotalBytes": -1314816,
"scriptDurationMs": 39.655,
"eventListeners": -155,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333332,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "minimap-idle",
"durationMs": 2050.814999999943,
"styleRecalcs": 4,
"styleRecalcDurationMs": 3.6869999999999994,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 584.042,
"heapDeltaBytes": -20707996,
"heapUsedBytes": 71966260,
"domNodes": -273,
"jsHeapTotalBytes": -1314816,
"scriptDurationMs": 38.147,
"eventListeners": -155,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333335,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "subgraph-dom-widget-clipping",
"durationMs": 741.1860000000274,
"styleRecalcs": 47,
"styleRecalcDurationMs": 10.204,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 523.989,
"heapDeltaBytes": 17848340,
"heapUsedBytes": 87845416,
"domNodes": 20,
"jsHeapTotalBytes": 5242880,
"scriptDurationMs": 143.18299999999996,
"eventListeners": 8,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "subgraph-dom-widget-clipping",
"durationMs": 730.4100000000062,
"styleRecalcs": 45,
"styleRecalcDurationMs": 8.790000000000001,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 495.2390000000001,
"heapDeltaBytes": -7899444,
"heapUsedBytes": 62842708,
"domNodes": 16,
"jsHeapTotalBytes": 6815744,
"scriptDurationMs": 131.697,
"eventListeners": 6,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.670000000000012,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "subgraph-idle",
"durationMs": 2022.8539999999953,
"styleRecalcs": 10,
"styleRecalcDurationMs": 9.286999999999999,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 565.577,
"heapDeltaBytes": -9902480,
"heapUsedBytes": 60910560,
"domNodes": -294,
"jsHeapTotalBytes": 4972544,
"scriptDurationMs": 9.616999999999999,
"eventListeners": -201,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "subgraph-idle",
"durationMs": 2007.863000000043,
"styleRecalcs": 8,
"styleRecalcDurationMs": 6.478,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 497.276,
"heapDeltaBytes": -3109432,
"heapUsedBytes": 67751752,
"domNodes": -297,
"jsHeapTotalBytes": 5234688,
"scriptDurationMs": 7.968000000000001,
"eventListeners": -231,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "subgraph-mouse-sweep",
"durationMs": 1874.4870000000446,
"styleRecalcs": 78,
"styleRecalcDurationMs": 39.789,
"layouts": 16,
"layoutDurationMs": 4.5889999999999995,
"taskDurationMs": 1151.116,
"heapDeltaBytes": 9295812,
"heapUsedBytes": 80068896,
"domNodes": -295,
"jsHeapTotalBytes": 5758976,
"scriptDurationMs": 113.427,
"eventListeners": -231,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333332,
"p95FrameDurationMs": 16.800000000000182
},
{
"name": "subgraph-mouse-sweep",
"durationMs": 1885.7699999999795,
"styleRecalcs": 78,
"styleRecalcDurationMs": 39.516000000000005,
"layouts": 16,
"layoutDurationMs": 4.597,
"taskDurationMs": 1120.538,
"heapDeltaBytes": 8987140,
"heapUsedBytes": 79538784,
"domNodes": -297,
"jsHeapTotalBytes": 6807552,
"scriptDurationMs": 116.797,
"eventListeners": -233,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "subgraph-transition-enter",
"durationMs": 1385.067999999933,
"styleRecalcs": 19,
"styleRecalcDurationMs": 29.495,
"layouts": 14,
"layoutDurationMs": 12.672,
"taskDurationMs": 914.533,
"heapDeltaBytes": -9272936,
"heapUsedBytes": 84842344,
"domNodes": 13671,
"jsHeapTotalBytes": 10223616,
"scriptDurationMs": 27.788,
"eventListeners": 2381,
"totalBlockingTimeMs": 124,
"frameDurationMs": 16.670000000000012,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "viewport-pan-sweep",
"durationMs": 12345.725000000017,
"styleRecalcs": 247,
"styleRecalcDurationMs": 40.373999999999995,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 9080.863,
"heapDeltaBytes": -6889148,
"heapUsedBytes": 84144960,
"domNodes": -271,
"jsHeapTotalBytes": 4120576,
"scriptDurationMs": 3049.6719999999996,
"eventListeners": -129,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "viewport-pan-sweep",
"durationMs": 12331.44900000002,
"styleRecalcs": 246,
"styleRecalcDurationMs": 38.445,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 9204.650000000001,
"heapDeltaBytes": -13478752,
"heapUsedBytes": 77833580,
"domNodes": -278,
"jsHeapTotalBytes": 3072000,
"scriptDurationMs": 3154.601,
"eventListeners": -129,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "vue-large-graph-idle",
"durationMs": 18474.279000000024,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 17800.986,
"heapDeltaBytes": -43623648,
"heapUsedBytes": 162155768,
"domNodes": -6548,
"jsHeapTotalBytes": -647168,
"scriptDurationMs": 391.193,
"eventListeners": -7473,
"totalBlockingTimeMs": 0,
"frameDurationMs": 17.780000000000047,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "vue-large-graph-idle",
"durationMs": 18255.618000000028,
"styleRecalcs": 0,
"styleRecalcDurationMs": 0,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 17501.846,
"heapDeltaBytes": -49345948,
"heapUsedBytes": 177327524,
"domNodes": -6548,
"jsHeapTotalBytes": -3018752,
"scriptDurationMs": 401.657,
"eventListeners": -7471,
"totalBlockingTimeMs": 0,
"frameDurationMs": 17.776666666666763,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "vue-large-graph-pan",
"durationMs": 22960.351999999944,
"styleRecalcs": 173,
"styleRecalcDurationMs": 24.12599999999998,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 22719.439000000002,
"heapDeltaBytes": -30384408,
"heapUsedBytes": 180511160,
"domNodes": -6548,
"jsHeapTotalBytes": -5066752,
"scriptDurationMs": 941.7629999999999,
"eventListeners": -7467,
"totalBlockingTimeMs": 39,
"frameDurationMs": 17.776666666666642,
"p95FrameDurationMs": 16.799999999999272
},
{
"name": "vue-large-graph-pan",
"durationMs": 22147.282000000017,
"styleRecalcs": 175,
"styleRecalcDurationMs": 21.49200000000004,
"layouts": 0,
"layoutDurationMs": 0,
"taskDurationMs": 21867.839999999997,
"heapDeltaBytes": -48069232,
"heapUsedBytes": 165254768,
"domNodes": -6548,
"jsHeapTotalBytes": -1318912,
"scriptDurationMs": 937.8539999999999,
"eventListeners": -7469,
"totalBlockingTimeMs": 68,
"frameDurationMs": 18.330000000000048,
"p95FrameDurationMs": 16.700000000000728
},
{
"name": "workflow-execution",
"durationMs": 488.93199999997705,
"styleRecalcs": 18,
"styleRecalcDurationMs": 21.654999999999998,
"layouts": 2,
"layoutDurationMs": 0.9269999999999999,
"taskDurationMs": 127.89699999999998,
"heapDeltaBytes": 5804928,
"heapUsedBytes": 72184388,
"domNodes": 148,
"jsHeapTotalBytes": 0,
"scriptDurationMs": 8.725999999999999,
"eventListeners": 99,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.666666666666668,
"p95FrameDurationMs": 16.699999999999818
},
{
"name": "workflow-execution",
"durationMs": 491.86699999995653,
"styleRecalcs": 14,
"styleRecalcDurationMs": 22.968000000000004,
"layouts": 3,
"layoutDurationMs": 0.8370000000000001,
"taskDurationMs": 133.828,
"heapDeltaBytes": 5452716,
"heapUsedBytes": 72453672,
"domNodes": 123,
"jsHeapTotalBytes": 262144,
"scriptDurationMs": 7.464000000000002,
"eventListeners": 97,
"totalBlockingTimeMs": 0,
"frameDurationMs": 16.66333333333332,
"p95FrameDurationMs": 16.800000000000182
}
]
} |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
Included review availability: Your plan provides up to 4 included reviews per hour; 2 remain after this review. 📝 WalkthroughWalkthroughThe local billing fixture now models unsubscribed workspaces. The local credits test mocks customer credit purchases and verifies the request payload, checkout URL, and dialog closure. ChangesLocal credit purchase flow
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to This test-only change corrects the unsubscribed-user precondition and verifies the Local/Desktop credit purchase request flow; no actionable merge-blocking risk remains after normal checks and review. Important Pre-merge checks failedPlease resolve all errors before merging. Addressing warnings is optional. ❌ Failed checks (1 inconclusive)
✅ Passed checks (6 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. @@ Coverage Diff @@
## main #15797 +/- ##
==========================================
+ Coverage 79.98% 82.39% +2.41%
==========================================
Files 2250 1920 -330
Lines 114155 109153 -5002
Branches 31543 30824 -719
==========================================
- Hits 91305 89935 -1370
+ Misses 22374 18882 -3492
+ Partials 476 336 -140
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
jaeone94
left a comment
There was a problem hiding this comment.
Could we stub window.open and assert the checkout URL here, as creditsTile.spec.ts does? The test currently only verifies the request and dialog closure, so it can pass even if checkout stops opening, while also allowing an external Stripe popup during E2E.
Stub window.open in an init script, as creditsTile.spec.ts does, and assert the mocked checkout_url is opened after POST /customers/credit. The purchase story now fails if checkout stops opening, and no real Stripe popup can escape the E2E.
|
@jaeone94 Done in 5192482. The spec now installs the same |
|
@dante01yoon Successfully backported to #15800 |
|
@dante01yoon Successfully backported to #15801 |
…-Org#15799) ## Summary An unsubscribed workspace on Local had no way to add credits: the subscribe CTA is hidden on Local (Comfy-Org#15601) but the Add credits button never appeared, because both entry points were gated on `canAccessSubscriptionFeatures` (QA finding #11 from the 1.51 workspace-switcher test plan). ## Changes - **What**: Gate the Add credits button in `CurrentUserPopoverWorkspace` and `CreditsTile` on the billing policy table (`topUpAccess === 'allowed'`) instead of `canAccessSubscriptionFeatures`. `showTopUpCreditsDialog` already enforces this same policy, so the buttons and the dialog now agree. The popover's free-tier upsell is likewise driven by `showsSubscribeUpsellUI`, which also stops the Cloud-only upgrade upsell from rendering on a Local free tier. - **Team workspaces**: the Plan & Credits panel forced the never-subscribed team prompt (`Subscribe now` + zero-state tile) on every distribution, so a never-subscribed team workspace on Local also had no top-up path. That prompt is now Cloud-only; the ended-team inactive treatment is unchanged everywhere so billing, invoices, and reactivation stay reachable. ## Review Focus - Cloud behavior is unchanged by construction: on Cloud, `topUpAccess === 'allowed'` only in states where `canAccessSubscriptionFeatures` is already true, and `CloudWithoutActiveSubscription`/`CloudAndFree` keep their previous surfaces (subscribe action / upgrade upsell). - On Local every policy state allows top-up, so the button now renders for unsubscribed workspaces; owner permission gating (`permissions.canTopUp`) is unchanged. - The bug only reproduces on the workspace billing rail (`billing_rail: 'stripe'`): the legacy rail exempts Local from the subscription gate, which is why the existing legacy-rail e2e passes on main. This PR adds `localCreditsWorkspaceRail.spec.ts` (own fixture, no shared-file changes, so no conflict with Comfy-Org#15797) covering the failing rail end to end. Needs backport to `core/1.51` after merge — this is a sign-off blocker for the 1.51 QA round. ## Screenshots Local build, workspace billing rail, no active subscription (`is_active: false`), owner. | Surface | AS IS (main) | TO BE (this PR) | | --- | --- | --- | | Profile popover |  |  | | Settings > Plan & Credits |  |  | AS IS: no Add credits button in either surface (and no Subscribe button on Local) — a dead end. TO BE: Add credits is available and opens the top-up dialog.
Summary
Correct the Local/Desktop billing E2E precondition so finding #11 is exercised as an unsubscribed user, then verify that the user can open Plan & Credits and complete the Add credits request flow.
The product routing fix and real-app UI change were merged in #15793; this PR is its test-only follow-up.
Root Cause
localAuthFixtureusedwithFreeTier(), which returns an active Free-tier subscription (is_active: true,subscription_tier: 'FREE'). Finding #11 concerns a logged-in Local/Desktop user with no active subscription (is_active: false).Those are distinct backend states. Billing UI eligibility is derived from the mocked subscription response, including
canTopUp, so the previous fixture could pass while exercising an active subscriber rather than the reported unsubscribed user story. It therefore did not provide deterministic regression coverage for the failure condition fixed in #15793.Fix
withFreeTier()withwithUnsubscribed()so the fixture returns the correct backend state:is_active: false,subscription_tier: 'FREE'.POST /customers/creditpayload and verify the top-up dialog closes after the accepted purchase request.The E2E now covers the Local profile popover, the routed Plan & Credits surface, absence of Cloud-only subscription actions, and Add credits from both surfaces. Immediate and polled top-up completion routing remain covered by the focused tests merged in #15793.
AS IS — wrong fixture precondition and legacy destination
The fixture modeled an active Free-tier subscriber, not an unsubscribed Local/Desktop user. Under the original product behavior, Plans and credits opened the legacy combined Credits + Activity page:
TO BE — unsubscribed precondition and Plan & Credits destination
The fixture now models the no-active-subscription state from finding #11, and the user story verifies the tabbed Plan & Credits page plus a working Add credits request:
Validation
pnpm exec oxfmt --check browser_tests/fixtures/localAuthFixture.ts browser_tests/tests/localCreditsNoSubscribeUi.spec.tspnpm exec eslint browser_tests/fixtures/localAuthFixture.ts browser_tests/tests/localCreditsNoSubscribeUi.spec.tspnpm typecheck:browsergit diff --checkDependencies
None. Based on
mainafter #15793.