MCPcopy Create free account

hub / github.com/PerpetualSoftware/pad / functions

Functions28,840 in github.com/PerpetualSoftware/pad

FunctionTestMeAgendaTzDefaults
(t *testing.T)
internal/server/handlers_me_agenda_test.go:355
FunctionTestMeAgendaUnavailableVisibility
(t *testing.T)
internal/server/handlers_me_agenda_caps_test.go:54
FunctionTestMeAgendaWindowValidation
(t *testing.T)
internal/server/handlers_me_agenda_test.go:377
FunctionTestMeAgendaWindowsPrecedeGroups
(t *testing.T)
internal/server/agenda_roundtrip_regression_test.go:161
FunctionTestMeAgendaWorkspaceContinuation
(t *testing.T)
internal/server/handlers_me_agenda_workspace_test.go:231
FunctionTestMeAgendaWorkspaceCountScanIsolation
(t *testing.T)
internal/server/handlers_me_agenda_workspace_test.go:19
FunctionTestMeAgendaWorkspaceGuestParity
(t *testing.T)
internal/server/handlers_me_agenda_workspace_test.go:142
FunctionTestMeAgendaWorkspaceParsing
(t *testing.T)
internal/server/handlers_me_agenda_workspace_test.go:175
FunctionTestMeAgendaWorkspacePinned
(t *testing.T)
internal/server/handlers_me_agenda_workspace_test.go:100
FunctionTestMeAgendaWorkspaceSameNameScope
(t *testing.T)
internal/server/handlers_me_agenda_workspace_test.go:259
FunctionTestMeAgendaWorkspaceUnavailable
(t *testing.T)
internal/server/handlers_me_agenda_workspace_test.go:56
FunctionTestMeNeedsDueHumanOccurrence
(t *testing.T)
internal/server/handlers_me_needs_due_test.go:11
FunctionTestMeNeedsDueNotOnOtherPersonsRow
(t *testing.T)
internal/server/handlers_me_needs_due_test.go:98
FunctionTestMeNeedsDueScopeBeforeCap
(t *testing.T)
internal/server/handlers_me_needs_due_test.go:125
FunctionTestMeNeedsSkipsUnreadableSchedule
(t *testing.T)
internal/server/agenda_unreadable_test.go:52
FunctionTestMe_EditorMember
TestMe_EditorMember pins the editor-with-all-access shape.
internal/server/handlers_me_test.go:43
FunctionTestMe_GuestWithItemGrant
TestMe_GuestWithItemGrant pins the guest path: a non-member with only an item_grant. /me uses GuestVisibleCollectionIDs which materializes the item-gr
internal/server/handlers_me_test.go:182
FunctionTestMe_NonMemberNoGrants_NoAccess
TestMe_NonMemberNoGrants_NoAccess confirms non-members with no grants are rejected upstream and never reach /me. The workspace resolver returns 404 (w
internal/server/handlers_me_test.go:272
FunctionTestMe_OwnerAdmin
TestMe_OwnerAdmin pins the admin/owner shape: collection_access "all", no visibility list, no grants. Admins are normalized by the auth middleware to
internal/server/handlers_me_test.go:13
FunctionTestMe_RestrictedMember
TestMe_RestrictedMember pins the collection_access="specific" path: both VisibleCollectionIDs (nav set) and FullAccessCollectionIDs (strict per-item a
internal/server/handlers_me_test.go:125
FunctionTestMe_ViewerWithCollectionGrant
TestMe_ViewerWithCollectionGrant pins the precedence-override case: a viewer with CollectionGrant.edit on one collection. The /me response must includ
internal/server/handlers_me_test.go:70
FunctionTestMeasure_BackfillEffortRead
(a) BackfillEffort's whole-table read on the 4,079-item shape and a 10x one, with an item writer running alongside to show what it costs a runtime wri
internal/store/runtime_pool_measure_test.go:115
FunctionTestMeasure_CrossWorkspaceCopyAndRemap
TestMeasure_CrossWorkspaceCopyAndRemap prints how long the cross-workspace copy (which holds both workspaces' advisory locks) and the attachment remap
internal/store/runtime_pool_measure_test.go:21
FunctionTestMeasure_LargestCopy
(b) The largest cross-workspace copy the UI allows. The copy is ONE item (no children, comments, versions or links carry); what scales is the item's b
internal/store/runtime_pool_measure_test.go:166
FunctionTestMeasure_RemapBeforeAfter
(c) Remap at 1,000 rewrites on the 4,079-item / ~20k-comment shape: total time and the longest an item writer waited, through the public API only, so
internal/store/runtime_pool_measure_test.go:212
FunctionTestMemberLimitRefusal_NativeShell
The invitee's member-limit refusal (BUG-3098) is its own message, not the plan-limit helpers', and it says "upgrade their plan". Both accept doors, th
internal/server/plan_limit_native_shell_test.go:271
FunctionTestMembershipGatesEveryActorMethod
TASK-4038: EnsureAgentDM is excluded because it takes no actor; its caller (TASK-4039) must pass the authenticated owner.
internal/store/conversations_test.go:1007
FunctionTestMemoryBusDropCounterIsMeaningfulWithoutRedis
TestMemoryBusDropCounterIsMeaningfulWithoutRedis pins which counters are live on a single-process deployment: the slow-subscriber drop moves (MemoryBu
internal/watchevents/observer_test.go:579
FunctionTestMemoryBusPublishAfterCloseDoesNotBurnSequence
TestMemoryBusPublishAfterCloseDoesNotBurnSequence asserts the OTHER half of the old behaviour — the part that is invisible in the return value. The un
internal/watchevents/publish_result_test.go:54
FunctionTestMemoryBusPublishAfterCloseReportsClosed
BUG-2699 — Publish reports acceptance. The pre-fix behaviour these pin is not "an error was swallowed": it is that a post-Close publish on MemoryBus
internal/watchevents/publish_result_test.go:24
FunctionTestMemoryBusPublishReportsClosedAfterClose
BUG-2732: Publish reports its outcome with the same three-way contract internal/watchevents' Publish has (BUG-2699): nil is accepted, ErrBusClosed is
internal/events/publish_outcome_test.go:17
FunctionTestMemoryBusReportsItsOwnResumeGaps
The cold-resume fix above sends clients sync_required, and MemoryBus reported nothing — RedisBus counts its own unservable resumes, so pad_watchevents
internal/watchevents/cold_resume_test.go:143
FunctionTestMemoryBusReportsSlowSubscriberDrop
TestMemoryBusReportsSlowSubscriberDrop asserts the DROP increments the observer — not merely that an observer can be attached. It asserts its own pre
internal/watchevents/observer_test.go:126
FunctionTestMemoryBusSignalsTheDroppedSubscriberOnly
TestMemoryBusSignalsTheDroppedSubscriberOnly is the same claim for the single-process implementation, which has no received-hole concept at all — it i
internal/watchevents/gap_signal_test.go:126
FunctionTestMemoryBus_ConcurrentPublishUnsubscribeClose_NoPanic
TestMemoryBus_ConcurrentPublishUnsubscribeClose_NoPanic covers this: Publish used to snapshot subscriber channels under the lock, release it, and send
internal/watchevents/watchevents_test.go:320
FunctionTestMemoryBus_ConcurrentPublish_MaintainsIDOrderInReplayBuffer
TestMemoryBus_ConcurrentPublish_MaintainsIDOrderInReplayBuffer covers the case where sequence assignment and replay-buffer insertion used to happen un
internal/watchevents/watchevents_test.go:198
FunctionTestMemoryBus_EventsSince_CaughtUpReturnsEmptyNotNil
(t *testing.T)
internal/watchevents/watchevents_test.go:126
FunctionTestMemoryBus_EventsSince_EvictedGapReturnsNil
(t *testing.T)
internal/watchevents/watchevents_test.go:144
FunctionTestMemoryBus_EventsSince_ReplaysNewerOnly
(t *testing.T)
internal/watchevents/watchevents_test.go:103
FunctionTestMemoryBus_MultipleSubscribersAllReceive
(t *testing.T)
internal/watchevents/watchevents_test.go:82
FunctionTestMemoryBus_PublishDeliversPushWithTargetUserID
TestMemoryBus_PublishDeliversPushWithTargetUserID covers IDEA-2544 Phase 1: KindPush and TargetUserID must round-trip through Publish like any other k
internal/watchevents/watchevents_test.go:40
FunctionTestMemoryBus_PublishDeliversToSubscriber
(t *testing.T)
internal/watchevents/watchevents_test.go:11
FunctionTestMemoryBus_SlowSubscriberDoesNotBlockPublish
(t *testing.T)
internal/watchevents/watchevents_test.go:167
FunctionTestMemoryBus_SubscribeAndReplaySince_NoDuplicateUnderConcurrentPublish
TestMemoryBus_SubscribeAndReplaySince_NoDuplicateUnderConcurrentPublish covers this: Subscribe() and EventsSince() used to be two separate calls, leav
internal/watchevents/watchevents_test.go:248
FunctionTestMemoryBus_UnsubscribeClosesChannel
(t *testing.T)
internal/watchevents/watchevents_test.go:69
FunctionTestMemoryOpBusCloseClosesAllChannels
TestMemoryOpBusCloseClosesAllChannels confirms Close cleans up every subscriber, regardless of which item they were watching.
internal/collab/bus_test.go:148
FunctionTestMemoryOpBusConcurrentPublish
TestMemoryOpBusConcurrentPublish confirms the bus survives many concurrent publishers without panicking or tripping the race detector on the subscribe
internal/collab/bus_test.go:173
FunctionTestMemoryOpBusSlowSubscriberDrops
TestMemoryOpBusSlowSubscriberDrops verifies that a subscriber whose channel buffer is full has events dropped instead of blocking the publisher. Witho
internal/collab/bus_test.go:74
FunctionTestMemoryOpBusSubscribeAndPublish
TestMemoryOpBusSubscribeAndPublish verifies basic fan-out: a subscriber receives every event for its itemID and ignores events for other items.
internal/collab/bus_test.go:13
FunctionTestMemoryOpBusSubscriberCount
TestMemoryOpBusSubscriberCount tracks the count across subscribe and unsubscribe.
internal/collab/bus_test.go:109
FunctionTestMemoryOpBusUnsubscribeClosesChannel
TestMemoryOpBusUnsubscribeClosesChannel confirms Unsubscribe removes the subscriber AND closes its channel, so handler `for ev := range ch { ... }` lo
internal/collab/bus_test.go:47
FunctionTestMemorySessionPresence_AddListRemove
(t *testing.T)
internal/server/session_presence_test.go:9
FunctionTestMemorySessionPresence_ArmedRoundTrips
TestMemorySessionPresence_ArmedRoundTrips is PLAN-2613 S1's wiring check for the registry layer: SessionIdentity.Armed must survive Add/ListForUser un
internal/server/session_presence_test.go:127
FunctionTestMemorySessionPresence_ConcurrentAccess
TestMemorySessionPresence_ConcurrentAccess is the race-detector's entry point for the connect/disconnect-vs-read pattern the stream handler produces i
internal/server/session_presence_test.go:153
FunctionTestMemorySessionPresence_ListIsOldestFirstAndStable
TestMemorySessionPresence_ListIsOldestFirstAndStable covers the ordering the S5 target picker relies on. Two sessions can share a ConnectedAt under a
internal/server/session_presence_test.go:74
FunctionTestMemorySessionPresence_ListReturnsACopy
TestMemorySessionPresence_ListReturnsACopy pins the doc-comment promise that a caller may retain the returned slice: mutating it must not reach back i
internal/server/session_presence_test.go:106
FunctionTestMemorySessionPresence_NotVisibleAcrossInstances
TestMemorySessionPresence_NotVisibleAcrossInstances is the NEGATIVE CONTROL for the test above, and it is what makes that test evidence rather than a
internal/server/session_presence_redis_test.go:69
FunctionTestMemorySessionPresence_RemoveIsForgiving
TestMemorySessionPresence_RemoveIsForgiving pins the contract the stream handler's defer depends on: Remove runs on exit paths where Add may never hav
internal/server/session_presence_test.go:53
FunctionTestMentionShapeParity
TestMentionShapeParity pins links.ExtractMentions's name shape to ValidateUsername's, ignoring the reserved list (TASK-3917).
internal/server/task3917_mention_shape_test.go:12
FunctionTestMergeActivityMeta
(t *testing.T)
internal/store/activities_test.go:602
FunctionTestMergeActivityMeta_CollapsesSameFieldRun
Regression for the BUG-1466 follow-up: when CreateActivityDebounced merges multiple PATCHes that all hit the same field, the merged `changes` string s
internal/store/activities_test.go:586
FunctionTestMergeActivityMeta_NullBlobDoesNotPanic
TestMergeActivityMeta_NullBlobDoesNotPanic covers the blob that is valid JSON, valid JSONB, storable in both dialects' columns — and unmarshals to a n
internal/store/activities_debounce_race_test.go:385
FunctionTestMergeAllowedWorkspaces
TestMergeAllowedWorkspaces covers the OR-merge policy for the dual-read introspection gate (PLAN-1519 / TASK-1520). The gate consults two sources duri
internal/server/middleware_mcp_auth_dual_read_test.go:26
FunctionTestMergeFieldsPatch
TestMergeFieldsPatch exercises the pure shallow-merge helper directly: set, delete-on-null, orphan-key preservation, and empty-base handling.
internal/store/items_fieldpatch_test.go:26
FunctionTestMergeIntoUnlinkedActivity_RefusesLinkedRow
TASK-2760: the debounce's read-then-write is two statements, and a comment can link the chosen row between them. The write itself must refuse a linked
internal/store/comments_agent_name_test.go:388
FunctionTestMergeIntoUnlinkedActivity_RefusesMovedRow
TestMergeIntoUnlinkedActivity_RefusesMovedRow drives the compare-and-set arm directly, on a row NO comment links — so the only thing that can refuse t
internal/store/activities_debounce_race_test.go:210
FunctionTestMergeParameters_EmptyInputs
(t *testing.T)
internal/urlimport/openapi_test.go:189
FunctionTestMergeYieldsEachInstantOnce
TestMergeYieldsEachInstantOnce holds the merge itself, below the settle the public calls apply: an RDATE equal to a rule occurrence, and an RDATE repe
internal/schedule/neverpartial_test.go:290
FunctionTestMetricsAuth_NoMetricsMeans404
TestMetricsAuth_NoMetricsMeans404 sanity-checks that /metrics is simply not routed when metrics are disabled (SetMetrics never called).
internal/server/metrics_auth_test.go:99
FunctionTestMetricsAuth_TokenSet_RequiresBearer
TestMetricsAuth_TokenSet_RequiresBearer: with PAD_METRICS_TOKEN set, every scrape — even loopback — must present the correct Bearer token.
internal/server/metrics_auth_test.go:62
FunctionTestMetricsAuth_TokenUnset_LoopbackOnly
TestMetricsAuth_TokenUnset_LoopbackOnly: no PAD_METRICS_TOKEN → loopback callers succeed, everyone else gets 403. Safe default for self-hosters runnin
internal/server/metrics_auth_test.go:45
FunctionTestMetricsMiddleware_RecordsRequestMetrics
(t *testing.T)
internal/server/middleware_metrics_test.go:14
FunctionTestMetricsMiddleware_UnmatchedRoute
(t *testing.T)
internal/server/middleware_metrics_test.go:110
FunctionTestMetricsMiddleware_UsesRoutePattern
(t *testing.T)
internal/server/middleware_metrics_test.go:75
FunctionTestMetricsToolLabelIsBounded
TestMetricsToolLabelIsBounded pins that the cleaned-identity marker costs exactly ONE extra Prometheus label value, not one per tool. The audit ROW k
internal/server/middleware_mcp_audit_test.go:650
FunctionTestMigrateCarriesCommitments
(t *testing.T)
cmd/pad/commitment_bundle_v2_test.go:50
FunctionTestMigrateCloseStateChange
BUG-2367 item 4: only the STATE is compared.
internal/models/close_state_test.go:6
FunctionTestMigrateFields_DefaultApplied
(t *testing.T)
internal/items/migrate_test.go:103
FunctionTestMigrateFields_DropsExtraFields
(t *testing.T)
internal/items/migrate_test.go:51
FunctionTestMigrateFields_GrandfatheredReservedDeclarationIsInert
A GRANDFATHERED schema can still declare a reserved key. Such a FieldDef must not reach the defaults/required pass: a Default would be injected into s
internal/items/migrate_test.go:471
FunctionTestMigrateFields_MatchingTypes
(t *testing.T)
internal/items/migrate_test.go:10
FunctionTestMigrateFields_NeverCarriesIntoComputed
BUG-2367: a computed destination field is the server's to populate, so a source that declares the same key as an ordinary field must not plant its lit
internal/items/migrate_test.go:502
FunctionTestMigrateFields_ReferentialKeysTravelOnlyWithinTheirContext
The carry rule's own qualifier (BUG-2674): system-minted NON-REFERENTIAL data carries everywhere; REFERENTIAL system data carries only where its refer
internal/items/migrate_test.go:252
FunctionTestMigrateFields_RequiredFieldMissing
(t *testing.T)
internal/items/migrate_test.go:89
FunctionTestMigrateFields_ReservedKeysBypassSchemaMatching
Reserved keys are carried by IDENTITY, not by name-matching against the target schema — so they survive even when the target happens to declare a fiel
internal/items/migrate_test.go:193
FunctionTestMigrateFields_ReservedKeysCarryThroughUntouched
BUG-2674. MigrateFields dropped every key absent from the TARGET schema, and implementation_notes / decision_log / github_pr / convention are reserved
internal/items/migrate_test.go:130
FunctionTestMigrateFields_SelectValueNotInTarget
(t *testing.T)
internal/items/migrate_test.go:34
FunctionTestMigrateFields_TypeConversion
(t *testing.T)
internal/items/migrate_test.go:68
FunctionTestMigrateImportNullSafeOnPG
(t *testing.T)
cmd/pad/commitment_bundle_v2_test.go:92
FunctionTestMigrateItemFieldValues_PerRowUniqueSeq
TestMigrateItemFieldValues_PerRowUniqueSeq guards the items-changes pagination contract on bulk rewrites (TASK-1354). Before the fix, the bulk UPDATE
internal/store/items_test.go:3004
FunctionTestMigrateMultiRelation_ABlankDefaultIsRemovedRatherThanLeftToFailValidation
THIRD-ORDER CASES. Two of the three were again in the previous fixes; the third is a pre-existing inconsistency the empty-list rule made visible.
internal/store/relation_multi_defaults_test.go:312
FunctionTestMigrateMultiRelation_ACarriedBlankBearingListIsDroppedNotRefused
CARRIED values, the third origin (PLAN-2857 U4). Rounds 1-4 settled SUPPLIED (refused) and DESTINATION DEFAULT (dropped) and left CARRIED on the leni
internal/store/relation_multi_defaults_test.go:595
FunctionTestMigrateMultiRelation_AMixedBlankDefaultIsDropped
(t *testing.T)
internal/store/relation_multi_defaults_test.go:483
FunctionTestMigrateMultiRelation_ASuppliedBlankOverrideIsLeftForValidationToRefuse
FOURTH-ORDER CASES — both were in the previous fix. The deletion it added ran BEFORE the origin split, so it treated a caller's malformed override exa
internal/store/relation_multi_defaults_test.go:432
FunctionTestMigrateMultiRelation_AnEmptySuppliedListIsStillACLEAR
(t *testing.T)
internal/store/relation_multi_defaults_test.go:464
FunctionTestMigrateMultiRelation_ControlAScalarClearedValueIsUntouched
(t *testing.T)
internal/store/relation_multi_defaults_test.go:342
FunctionTestMigrateMultiRelation_ControlAWellFormedCarriedListSurvives
(t *testing.T)
internal/store/relation_multi_defaults_test.go:625
FunctionTestMigrateMultiRelation_ControlAWellFormedDefaultSurvives
(t *testing.T)
internal/store/relation_multi_defaults_test.go:513
FunctionTestMigratePreflightRefusesCommitmentNUL
(t *testing.T)
cmd/pad/cmd_db_nul_test.go:555
FunctionTestMigrateRelationReferents_CrossWorkspaceDropsEveryCarriedRelation
(t *testing.T)
internal/store/relation_referents_test.go:312
← previousnext →21,401–21,500 of 28,840, ranked by callers