MCPcopy Create free account

hub / github.com/PerpetualSoftware/pad / functions

Functions28,840 in github.com/PerpetualSoftware/pad

FunctionTestOpenChildrenGuard_NoOpTerminal_NotGuarded
(t *testing.T)
internal/server/handlers_items_open_children_guard_test.go:252
FunctionTestOpenChildrenGuard_NonTerminalTransition_NotGuarded
(t *testing.T)
internal/server/handlers_items_open_children_guard_test.go:190
FunctionTestOpenChildrenGuard_PatchAtomicRejectionPreservesParentLink
TestOpenChildrenGuard_PatchAtomicRejectionPreservesParentLink covers the rule that a PATCH that combines a parent-link change AND a status flip to ter
internal/server/handlers_items_open_children_guard_test.go:1292
FunctionTestOpenChildrenGuard_PrecheckReadsInTxSnapshot
TestOpenChildrenGuard_PrecheckReadsInTxSnapshot covers the case where the precheck classifies the transition against the parent's fields as read INSID
internal/server/handlers_items_open_children_guard_test.go:1009
FunctionTestOpenChildrenGuard_RejectsTerminalWithOpenChildren
(t *testing.T)
internal/server/handlers_items_open_children_guard_test.go:54
FunctionTestOpenChildrenGuard_SoftDeletedCollectionSchemaHonored
TestOpenChildrenGuard_SoftDeletedCollectionSchemaHonored covers When a child still exists in a soft-deleted collection whose schema has a custom termi
internal/server/handlers_items_open_children_guard_test.go:893
FunctionTestOpenChildrenGuard_TOCTOURace
TestOpenChildrenGuard_TOCTOURace covers this invariant: a child status flip that races a parent-terminal update must NOT slip past the guard. The race
internal/server/handlers_items_open_children_guard_test.go:608
FunctionTestOpenChildrenGuard_TerminalToTerminal_NotGuarded
(t *testing.T)
internal/server/handlers_items_open_children_guard_test.go:206
FunctionTestOpenChildrenGuard_UsesCollectionTerminalOptions
(t *testing.T)
internal/server/handlers_items_open_children_guard_test.go:277
FunctionTestOpenChildrenGuard_VisibilityLookupErrorFailsClosed
TestOpenChildrenGuard_VisibilityLookupErrorFailsClosed covers the case where the visibility lookup errors (DB unavailable, etc.) the handler must fail
internal/server/handlers_items_open_children_guard_test.go:963
FunctionTestOpenChildrenGuard_VisibilitySanitizesPayload
TestOpenChildrenGuard_VisibilitySanitizesPayload covers the case where a restricted caller updates a parent they CAN see but the parent has children i
internal/server/handlers_items_open_children_guard_test.go:376
FunctionTestOpenChildrenScheduleActiveDetails
(t *testing.T)
internal/server/handlers_items_schedule_active_test.go:166
FunctionTestOpenMentions_ReplyClosesAndEditReopens
(t *testing.T)
internal/store/needs_read_test.go:148
FunctionTestOpenWorldActions_NoStaleEntries
TestOpenWorldActions_NoStaleEntries: every openWorldActions entry names a real catalog (tool, action) pair. Reads are allowed: open-world is where dat
internal/mcp/catalog_annotations_test.go:150
FunctionTestOpeningAGateReadsTheUnfilteredEvaluation
The acting function takes no reader: it sees every gate, hidden ones included.
internal/store/commitment_gates_display_test.go:69
FunctionTestOrdinaryEventsStillCarryTheirID
The control: an ordinary event still carries its real id, or clients would never advance their cursor at all.
internal/server/handlers_events_resume_test.go:129
FunctionTestOrdinarySuggestionsCarryNoReminderID
TestOrdinarySuggestionsCarryNoReminderID is the negative control: the field is omitempty and must stay empty on a plain task suggestion, or a consumer
internal/server/handlers_reminders_test.go:378
FunctionTestOrdinaryTrafficKeepsTheInstanceAlive
TestOrdinaryTrafficKeepsTheInstanceAlive pins that inbound frames stamp liveness. Without it the detector would cycle a connection that is plainly wor
internal/watchevents/heartbeat_test.go:426
FunctionTestOrphanGC_ClaimRefusesFreshlyReferencedRow
TestOrphanGC_ClaimRefusesFreshlyReferencedRow pins BUG-2415 at the sweep level: a never-attached row whose last_referenced_at stamp is FRESH (a writer
internal/server/orphan_gc_test.go:612
FunctionTestOrphanGC_DedupesBlobReclaimMetric
TestOrphanGC_DedupesBlobReclaimMetric pins that when multiple soft-deleted peers share a content_hash and all are past grace, the blob is deleted on t
internal/server/orphan_gc_test.go:487
FunctionTestOrphanGC_KeepsAttachmentReferencedFromComment
TestOrphanGC_KeepsAttachmentReferencedFromComment is the IDEA-1650 sibling of the item-content case above: a screenshot pasted into a comment is refer
internal/server/orphan_gc_test.go:290
FunctionTestOrphanGC_KeepsBlobForAnUploadThatCommitsAfterTheCount
(t *testing.T)
internal/server/task4279_blob_reclaim_race_test.go:31
FunctionTestOrphanGC_KeepsBlobWhenTheRecountCannotAnswer
A recount that cannot answer (here: the sweep's context ends between the early count and the lock) must keep the blob, never delete on an unknown.
internal/server/task4279_blob_reclaim_race_test.go:132
FunctionTestOrphanGC_KeepsRecentRows
TestOrphanGC_KeepsRecentRows pins the safety case: rows still inside the grace window MUST NOT be reclaimed. Catches a typo in the WHERE clause that w
internal/server/orphan_gc_test.go:121
FunctionTestOrphanGC_KeepsReferencedNeverAttachedRows
TestOrphanGC_KeepsReferencedNeverAttachedRows pins (PR #307) that the editor's normal upload flow leaves attachments.item_id NULL and only the markdow
internal/server/orphan_gc_test.go:243
FunctionTestOrphanGC_PreservesSharedBlob
TestOrphanGC_PreservesSharedBlob pins the dedupe-safety case: when two rows reference the same content_hash and only one is orphan, the row gets hard-
internal/server/orphan_gc_test.go:154
FunctionTestOrphanGC_ReclaimsLeakedLiveVariant
TestOrphanGC_ReclaimsLeakedLiveVariant pins the retro-cleanup class: a LIVE variant row under a tombstoned parent (the pre-fix leak artifact — inserte
internal/server/handlers_attachments_thumbnails_test.go:466
FunctionTestOrphanGC_ReclaimsLongOrphans
TestOrphanGC_ReclaimsLongOrphans pins the never-attached path: rows with item_id IS NULL AND deleted_at IS NULL aged past the grace period get reclaim
internal/server/orphan_gc_test.go:86
FunctionTestOrphanGC_ReclaimsSoftDeleted
TestOrphanGC_ReclaimsSoftDeleted pins TASK-886's main case: a soft-deleted attachment past the grace period gets hard-deleted from the DB AND its blob
internal/server/orphan_gc_test.go:19
FunctionTestOrphanGC_RespectsInFlightUploads
TestOrphanGC_RespectsInFlightUploads pins that an upload that called Put but hasn't yet inserted the attachments row must NOT lose its blob to GC recl
internal/server/orphan_gc_test.go:353
FunctionTestOrphanGC_RespectsSoftDeletedInGracePeer
TestOrphanGC_RespectsSoftDeletedInGracePeer pins that when two rows share a content_hash, GC reclaims the older one past grace but MUST NOT delete the
internal/server/orphan_gc_test.go:404
FunctionTestOrphanGC_StartStop
TestOrphanGC_StartStop pins the lifecycle: StartOrphanGC kicks the loop, Stop signals it to exit, and Server.Stop() actually drains. Catches regressio
internal/server/orphan_gc_test.go:588
FunctionTestOrphanGC_VariantProtectedByReferencedParent
TestOrphanGC_VariantProtectedByReferencedParent pins the parent-aware half of BUG-2415: content references an ORIGINAL's id, never a thumbnail's, so a
internal/server/orphan_gc_test.go:692
FunctionTestOrphanedReminderSkippedImport
Orphans must not abort a restore or disturb the other reminders' bundle positions.
internal/store/reminders_test.go:1379
FunctionTestOrphanedVariant_ForeignParentDoesNotShield
TestOrphanedVariant_ForeignParentDoesNotShield pins BUG-2622: the orphaned-variant class's parent check is workspace-scoped. A variant row whose paren
internal/store/attachments_gc_claim_test.go:433
FunctionTestOutboxClaimAlwaysTakesOneRowOverBudget
(t *testing.T)
internal/store/event_outbox_bounds_test.go:220
FunctionTestOutboxClaimSkipsRowsOverTheRowCapWithoutJamming
(t *testing.T)
internal/store/event_outbox_bounds_test.go:243
FunctionTestOutboxClaimSpendsTheBudgetOnBatchSiblingsToo
(t *testing.T)
internal/store/event_outbox_bounds_test.go:294
FunctionTestOutboxClaimStopsAtTheByteBudget
(t *testing.T)
internal/store/event_outbox_bounds_test.go:172
FunctionTestOutboxClaimStopsAtTheRowCap
(t *testing.T)
internal/store/event_outbox_bounds_test.go:495
FunctionTestOutboxDrainTickConsultsTheThrottle
TestOutboxDrainTickConsultsTheThrottle covers the CALL SITE, which the test above does not. Found by mutation: replacing `if s.shouldScanOversizedOut
internal/server/outbox_payload_limit_test.go:117
FunctionTestOutboxDrain_DeliversAndAcksASingleEvent
TestOutboxDrain_DeliversAndAcksASingleEvent is the base case: a stored event reaches the wire once, carrying its row id as the dedupe key, and stops b
internal/server/outbox_drain_test.go:103
FunctionTestOutboxDrain_FoldsABatchIntoOneWireEvent
TestOutboxDrain_FoldsABatchIntoOneWireEvent is the F2 payoff: a lane-wide bulk action must reach a webhook consumer as ONE delivery carrying every mem
internal/server/outbox_drain_test.go:214
FunctionTestOutboxDrain_MembersWithoutTheirHeaderDeliverIndividually
TestOutboxDrain_MembersWithoutTheirHeaderDeliverIndividually pins the window SPEC-3 v1.6 defines rather than papers over: a tick can claim some member
internal/server/outbox_drain_test.go:289
FunctionTestOutboxDrain_PermanentFailureAcks
TestOutboxDrain_PermanentFailureAcks: an endpoint that rejects the delivery in a way no retry fixes must not hold the workspace's queue. The control l
internal/server/outbox_drain_test.go:172
FunctionTestOutboxDrain_RetentionRefusesANonPositiveWindow
TestOutboxDrain_RetentionRefusesANonPositiveWindow pins the guard on the one configuration mistake that is unrecoverable. A zero window makes the ret
internal/server/outbox_drain_test.go:373
FunctionTestOutboxDrain_SettingsResolveToPositiveDefaults
TestOutboxDrain_SettingsResolveToPositiveDefaults is the primary defence the guard above backs up: every knob has a usable value no matter which entry
internal/server/outbox_drain_test.go:407
FunctionTestOutboxDrain_TransientFailureLeavesTheEventPending
TestOutboxDrain_TransientFailureLeavesTheEventPending: the durable retry is the drain's, and it is the reason the outbox exists. A 5xx must not ack.
internal/server/outbox_drain_test.go:148
FunctionTestOutboxLimitSeamsDefaultToTheProductionConstants
(t *testing.T)
internal/store/event_outbox_bounds_test.go:57
FunctionTestOutboxMemberSnapshotsMatchPerMemberReads
BUG-2718: outboxMemberSnapshotsTx reads its members in batches instead of one joined read per member. What it returns must be exactly what the per-mem
internal/store/bug2718_member_snapshots_test.go:19
FunctionTestOutboxRefusesAPayloadOverTheRowCap
(t *testing.T)
internal/store/event_outbox_bounds_test.go:105
FunctionTestOutbox_AttachmentAddedSkipsVariants
(t *testing.T)
internal/store/event_outbox_test.go:551
FunctionTestOutbox_BareStatusFlipEmitsStatusChangedOnly
(t *testing.T)
internal/store/event_outbox_test.go:111
FunctionTestOutbox_ClaimArbitratesTheRaceNotJustTheQuery
TestOutbox_ClaimArbitratesTheRaceNotJustTheQuery drives the conditional UPDATE with a STALE candidate list — the case the public entry point cannot pr
internal/store/event_outbox_test.go:1913
FunctionTestOutbox_ClaimIsExclusiveUntilTheLeaseExpires
TestOutbox_ClaimIsExclusiveUntilTheLeaseExpires is the multi-instance guard. Every instance of a cloud deployment runs the drain, so without the claim
internal/store/event_outbox_test.go:1774
FunctionTestOutbox_ClaimTakesWholeBatchesPastTheLimit
TestOutbox_ClaimTakesWholeBatchesPastTheLimit pins the rule that keeps a folded wire event true: the limit is a throughput knob, and letting it split
internal/store/event_outbox_test.go:1818
FunctionTestOutbox_CollectionOptionRenameEmitsOneBulkEvent
(t *testing.T)
internal/store/event_outbox_test.go:689
FunctionTestOutbox_CommentCreateAndUpdateEmit
(t *testing.T)
internal/store/event_outbox_test.go:505
FunctionTestOutbox_CommentDeleteEmitsRefOnly
(t *testing.T)
internal/store/event_outbox_test.go:1099
FunctionTestOutbox_CreateEmitsItemCreatedWithSnapshot
(t *testing.T)
internal/store/event_outbox_test.go:83
FunctionTestOutbox_CrossWorkspaceMoveEmitsSourceArchive
TestOutbox_CrossWorkspaceMoveEmitsSourceArchive pins the gap that made this test exist. archiveItemForCopyTx deliberately REPRODUCES DeleteItem's UPD
internal/store/event_outbox_test.go:631
FunctionTestOutbox_DeleteEmitsPreArchiveSnapshot
(t *testing.T)
internal/store/event_outbox_test.go:413
FunctionTestOutbox_FailedAttemptReleasesTheClaim
TestOutbox_FailedAttemptReleasesTheClaim: a transient failure means the event is still owed and nothing is in flight, so the next tick must be able to
internal/store/event_outbox_test.go:1863
FunctionTestOutbox_MemberJoinedEmits
(t *testing.T)
internal/store/event_outbox_test.go:598
FunctionTestOutbox_MixedUpdateEmitsBothSlices
(t *testing.T)
internal/store/event_outbox_test.go:141
FunctionTestOutbox_MoveEmitsMovedOnlyWhenNothingElseChanged
(t *testing.T)
internal/store/event_outbox_test.go:486
FunctionTestOutbox_NeverAttachedClaimEmitsNothing
(t *testing.T)
internal/store/event_outbox_test.go:1191
FunctionTestOutbox_NoOpCommentEditEmitsNothing
(t *testing.T)
internal/store/event_outbox_test.go:888
FunctionTestOutbox_NoOpUpdateEmitsNothing
(t *testing.T)
internal/store/event_outbox_test.go:185
FunctionTestOutbox_NonStatusUpdateEmitsUpdatedOnly
(t *testing.T)
internal/store/event_outbox_test.go:166
FunctionTestOutbox_ParentDetachEmitsOnEveryRoute
TestOutbox_ParentDetachEmitsOnEveryRoute closes the loop opened: attach was observable on every route while DETACH was silent on two of the three, so
internal/store/event_outbox_test.go:2314
FunctionTestOutbox_ParentOnlyUpdateStillEmits
TestOutbox_ParentOnlyUpdateStillEmits covers the path SetParentLink's fix did NOT reach: UpdateItemWithParentLink writes the hierarchy inside the item
internal/store/event_outbox_test.go:2257
FunctionTestOutbox_PayloadsOmitAssigneeIdentity
TestOutbox_PayloadsOmitAssigneeIdentity pins the privacy-lifecycle property. An outbox payload is a frozen snapshot that outlives its subject by desi
internal/store/event_outbox_test.go:1059
FunctionTestOutbox_PruneUndispatchedBoundsTheFrozenPayloadWindow
TestOutbox_PruneUndispatchedBoundsTheFrozenPayloadWindow pins the privacy half of retention (TASK-2714 requirement 3). PruneDispatchedOutbox filters
internal/store/event_outbox_test.go:1589
FunctionTestOutbox_PruneUndispatchedSparesAClaimedRow
TestOutbox_PruneUndispatchedSparesAClaimedRow: every instance runs retention, so without a claim check one instance's prune deletes a row another is m
internal/store/event_outbox_test.go:2140
FunctionTestOutbox_RedeleteEmitsNothing
(t *testing.T)
internal/store/event_outbox_test.go:442
FunctionTestOutbox_RestoreEmitsItemRestored
(t *testing.T)
internal/store/event_outbox_test.go:465
FunctionTestOutbox_SetParentLinkEmitsItemUpdated
TestOutbox_SetParentLinkEmitsItemUpdated pins the fix for the create-with- parent regression. CreateItem commits item.created with a PRE-LINK snapsho
internal/store/event_outbox_test.go:2190
FunctionTestOutbox_SoftDeletedAttachmentClaimEmitsRefOnly
(t *testing.T)
internal/store/event_outbox_test.go:1140
FunctionTestOutbox_StaleClaimCannotAckOrReleaseAnotherPass
TestOutbox_StaleClaimCannotAckOrReleaseAnotherPass pins the lease's other half. Delivery can outrun the lease — a workspace with many slow endpoints i
internal/store/event_outbox_test.go:2072
FunctionTestOutbox_StatusChangeFromEmptyCarriesEmptyPriorStatus
TestOutbox_StatusChangeFromEmptyCarriesEmptyPriorStatus pins the SPEC-3 conformance point: prior_status must be PRESENT on item.status_changed even wh
internal/store/event_outbox_test.go:1006
FunctionTestOutbox_VariantClaimEmitsNothing
TestOutbox_VariantClaimEmitsNothing pins the symmetry missing: a row that could not have emitted attachment.added must not emit attachment.removed. V
internal/store/event_outbox_test.go:1234
FunctionTestOutbox_WikiTitleCascadeEmitsOneBulkEvent
(t *testing.T)
internal/store/event_outbox_test.go:765
FunctionTestOutbox_WithEventBatchStampsEveryMutationPath
TestOutbox_WithEventBatchStampsEveryMutationPath drives ALL FIVE store entry points the bulk handler reaches, because the failure this guards against
internal/store/event_outbox_test.go:1672
FunctionTestOutputStrictlyIncreasingAcrossDST
TestOutputStrictlyIncreasingAcrossDST is the ORDER INVARIANT: Resolve is not monotonic inside a gap (02:59 -> 07:59Z but 03:00 -> 07:00Z), yet the out
internal/schedule/dst_test.go:72
FunctionTestOverdueIgnoresTerminalItems
TestOverdueIgnoresTerminalItems guards the direction a "surface it everywhere" change breaks: a DONE item with a past due date is not late, it is fini
internal/server/overdue_surfaces_test.go:140
FunctionTestOverdueOutranksInProgressWithinTheCap
TestOverdueOutranksInProgressWithinTheCap — leg 3's teeth. The list is capped at three, so ranking overdue BELOW in-progress does not merely order it
internal/server/overdue_surfaces_test.go:108
FunctionTestOverdueReachesDashboardAttention
TestOverdueReachesDashboardAttention — leg 1.
internal/server/overdue_surfaces_test.go:29
FunctionTestOverdueReachesReadyAndNext
TestOverdueReachesReadyAndNext — leg 3, and the one that would have failed before this unit. `ready` and `next` both render dashboard.suggested_next.
internal/server/overdue_surfaces_test.go:77
FunctionTestOverdueReachesStale
TestOverdueReachesStale — leg 2. `pad project stale` consumes the dashboard's attention list and keeps four types; the CLI-side filter is pinned in cm
internal/server/overdue_surfaces_test.go:52
FunctionTestOverriddenArmedFloatingRowRetimesFromTheOverride
An ARMED floating row carrying next_override_at (a C2b snooze or move; set by SQL here because C2a has no writer): the exact instant in next_at is nev
internal/store/schedule_outstanding_test.go:65
FunctionTestOverridePaths_EffortCandidatesRead
BackfillEffort's whole-table read waits out a lock the bounded default would have failed on.
internal/store/runtime_pool_test.go:497
FunctionTestOverridePaths_RunWithRaisedLimits
Each long-write path outlasts the runtime bound and must still succeed, with its own override visible INSIDE its transaction. A trigger on items sleep
internal/store/runtime_pool_test.go:337
FunctionTestOversizedArrayKeyIsNotFormatted
(t *testing.T)
internal/logging/redaction_followups_test.go:1368
FunctionTestOversizedOutboxScanIsThrottled
TestOversizedOutboxScanIsThrottled pins the diagnostic's cadence. The query it gates is expensive exactly when it finds nothing — a non-sargable size
internal/server/outbox_payload_limit_test.go:90
FunctionTestOversizedStateSurfacesTypedError
--------------------------------------------------------------------------- Errors -------------------------------------------------------------------
internal/decision/decision_test.go:290
FunctionTestOversizedStringStateIsTruncatedAndFlagged
--------------------------------------------------------------------------- Truncation ---------------------------------------------------------------
internal/decision/decision_test.go:507
FunctionTestOweDecisionJobs_DebounceAndCoalescing
TASK-3921: OweDecisionJobs and the backfill candidate query. Both backends via testStore.
internal/store/decisions_owe_test.go:12
FunctionTestOwedDecisionJobs
(t *testing.T)
internal/store/needs_scoring_test.go:102
FunctionTestOwnerCompensation_CompletesUnderASingleConnection
THE MaxOpenConns(1) QUESTION, SETTLED RATHER THAN DEFERRED (BUG-2715). The design discussion for this fix kept citing BUG-2778 and BUG-2409 — a pool
internal/server/workspace_owner_compensation_test.go:362
← previousnext →22,101–22,200 of 28,840, ranked by callers