@bongos/core 1.19.408 → 1.19.410
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.bongos-core.json +50 -35
- package/clients/bongos-client/README.md +1 -1
- package/clients/bongos-client/bongos-client.global.js +4 -0
- package/clients/bongos-client/index.cjs +4 -0
- package/clients/bongos-client/index.d.ts +6 -1
- package/clients/bongos-client/index.mjs +4 -0
- package/docs/api/openapi.json +124 -4
- package/docs/api-reference.md +5 -3
- package/docs/copy-inventory.md +43 -36
- package/docs/copy-registry.json +122 -39
- package/migrations/core_229_goals_accepting_requests.sql +37 -0
- package/modules/dev-box/app/src/vendor/bongos-client.cjs +4 -0
- package/modules/hall-ui/public/goals-page.js +26 -2
- package/modules/hall-ui/public/goals-render.js +35 -0
- package/modules/lifecycle/db-goals.js +22 -1
- package/modules/lifecycle/db.js +4 -1
- package/modules/lifecycle/goal-edits.js +40 -0
- package/modules/lifecycle/routes/goal-route-authz.js +51 -1
- package/modules/lifecycle/routes/goals.js +46 -1
- package/modules/platform-identity/migrations/platform_identity_012_recent_ships.sql +40 -0
- package/modules/platform-identity/platform-identity.js +87 -6
- package/modules/platform-identity/routes/sso.js +10 -0
- package/modules/platform-identity/tests/platform-identity.mjs +7 -2
- package/package-lock.json +2 -2
- package/package.json +1 -1
- package/src/bongos/auth-admission.js +89 -8
- package/src/bongos/route-rank-check.js +6 -0
- package/src/bongos/routes/auth.js +21 -0
- package/src/module-api.js +5 -1
- package/tests/goal_membership_requests.mjs +154 -1
- package/tests/hub_recent_ships.mjs +373 -0
- package/tests/prose_edits.mjs +8 -4
package/tests/prose_edits.mjs
CHANGED
|
@@ -182,16 +182,20 @@ await test('ROUTE SHAPE: the author gate is fail-closed and uses the array form
|
|
|
182
182
|
assert.match(src, /captured_by != null/, 'and the author check treats a NULL author as not-you');
|
|
183
183
|
});
|
|
184
184
|
|
|
185
|
-
await test('ROUTE SHAPE:
|
|
186
|
-
//
|
|
187
|
-
// of operation behind the same gate; this pins that they still are.
|
|
185
|
+
await test('ROUTE SHAPE: every goal-edit handler shares ONE authority gate', () => {
|
|
186
|
+
// Each was moved into goal-edits.js precisely because they are the same kind
|
|
187
|
+
// of operation behind the same gate; this pins that they still are. The count
|
|
188
|
+
// grows with the file — task 1002971 added the D6 accepting-requests toggle,
|
|
189
|
+
// the third write to a goal's own row behind authorizeGoalManagement.
|
|
188
190
|
const src = readFileSync(new URL('../modules/lifecycle/goal-edits.js', import.meta.url), 'utf8');
|
|
189
|
-
assert.equal((src.match(/authorizeGoalManagement\(/g) || []).length,
|
|
191
|
+
assert.equal((src.match(/authorizeGoalManagement\(/g) || []).length, 3, 'prose + visibility + accepting-requests, all gated');
|
|
190
192
|
assert.equal(typeof goalEdits.goalProseHandler, 'function');
|
|
191
193
|
assert.equal(typeof goalEdits.goalVisibilityHandler, 'function');
|
|
194
|
+
assert.equal(typeof goalEdits.goalAcceptingRequestsHandler, 'function');
|
|
192
195
|
const routes = readFileSync(new URL('../modules/lifecycle/routes/goals.js', import.meta.url), 'utf8');
|
|
193
196
|
assert.match(routes, /router\.patch\('\/goals\/:id',/, 'the REGISTRATION stays in the route file so route-rank-check sees it');
|
|
194
197
|
assert.match(routes, /router\.patch\('\/goals\/:id\/visibility',/);
|
|
198
|
+
assert.match(routes, /router\.patch\('\/goals\/:id\/accepting-requests',/);
|
|
195
199
|
});
|
|
196
200
|
|
|
197
201
|
// ---- 5. THE HANDLERS ARE ACTUALLY INVOKED ---------------------------------
|