Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/PerpetualSoftware/pad
/ functions
Functions
28,840 in github.com/PerpetualSoftware/pad
⨍
Functions
28,840
◇
Types & classes
3,245
Function
TestSessionRegistry_ReadFromForeignPIDNamespace
TestSessionRegistry_ReadFromForeignPIDNamespace is BUG-4090's reproduction: a row for a LIVE host session, read by `pad session list` and `pad session
internal/cli/session_owner_pidns_linux_test.go:56
Function
TestSessionResetClearsDirection
(t *testing.T)
cmd/pad/cmd_chat_direction_test.go:148
Function
TestSessionUAChange_LogOnlyDefault
TestSessionUAChange_LogOnlyDefault verifies that without PAD_IP_CHANGE_ENFORCE=strict a session that presents a different User-Agent is allowed throug
internal/server/middleware_session_ua_test.go:71
Function
TestSessionUAChange_StrictBearerRevokes
TestSessionUAChange_StrictBearerRevokes verifies the same enforcement on the CLI session-bearer path (Authorization: Bearer padsess_...), which runs t
internal/server/middleware_session_ua_test.go:137
Function
TestSessionUAChange_StrictRevokes
TestSessionUAChange_StrictRevokes verifies that with strict enforcement a session presenting a different User-Agent is rejected (401), the session is
internal/server/middleware_session_ua_test.go:104
Function
TestSession_AllowedWorkspaces_DefensiveCopy
TestSession_AllowedWorkspaces_DefensiveCopy verifies the setter copies the input — caller-side mutation of the slice after the call must not bleed int
internal/oauth/session_test.go:42
Function
TestSession_AllowedWorkspaces_JSONRoundTrip
TestSession_AllowedWorkspaces_JSONRoundTrip pins the critical integration path: the value survives JSON marshal+unmarshal (which is what storage.go's
internal/oauth/session_test.go:66
Function
TestSession_AllowedWorkspaces_NilInput
TestSession_AllowedWorkspaces_NilInput pins the "clear" semantics: SetAllowedWorkspaces(nil) removes the entry from Extra so a subsequent AllowedWorks
internal/oauth/session_test.go:29
Function
TestSession_AllowedWorkspaces_NilSession
TestSession_AllowedWorkspaces_NilSession is a paranoid nil-safety check for callers that might invoke the accessor on a freshly- declared zero-value S
internal/oauth/session_test.go:118
Function
TestSession_AllowedWorkspaces_NotSet
TestSession_AllowedWorkspaces_NotSet covers the legacy / pre-TASK-952 path: a session without an allowed_workspaces key must return nil so RequireWork
internal/oauth/session_test.go:108
Function
TestSession_AllowedWorkspaces_Setter_Getter
TestSession_AllowedWorkspaces_Setter_Getter pins the in-memory round-trip: SetAllowedWorkspaces([...]) then AllowedWorkspaces() returns the same list.
internal/oauth/session_test.go:15
Function
TestSession_AllowedWorkspaces_WildcardJSONRoundTrip
TestSession_AllowedWorkspaces_WildcardJSONRoundTrip pins the wildcard form — same JSON path, but the value is the single- element ["*"] form the conse
internal/oauth/session_test.go:90
Function
TestSession_CloneReturnsConcreteSession
===================================================================== Session — cloning and accessor =================================================
internal/oauth/server_test.go:398
Function
TestSession_NilSafeAccessors
(t *testing.T)
internal/oauth/server_test.go:422
Function
TestSessionsDir_TightensExistingMode
TestSessionsDir_TightensExistingMode: a pre-existing permissive directory is re-tightened to 0700 on every use.
internal/cli/session_registry_test.go:637
Function
TestSetAndValidateTracksWork
(t *testing.T)
internal/models/tracks_work_test.go:97
Function
TestSetAsideHintMatchesAcrossPackages
BUG-3244 ruling 1 at the MCP doors: an agent told about set-aside edits must not be told that waiting, re-reading or opening the item stores them. Eac
internal/mcp/bug3244_set_aside_test.go:19
Function
TestSetAsideHintSelectedOnHTTP
Remote: the same selection from the server's response body.
internal/mcp/bug3244_set_aside_test.go:56
Function
TestSetAsideHintSelectedOnStdio
Stdio: the CLI's marker line carries the hint the refusal's details select, and the classifier lifts it as-is.
internal/mcp/bug3244_set_aside_test.go:30
Function
TestSetAsideImportSkipsMalformedRows
A bundle row that did not come from a server is skipped, not stored and not fatal: this file's lenient import precedent.
internal/store/bug3244_set_aside_test.go:130
Function
TestSetAsideKeepsARowAppendedInsideTheMove
BUG-3244: the rebuild's setup lock does not stop a connected peer appending, and on Postgres each statement in the move takes its own snapshot. A cont
internal/store/bug3244_set_aside_race_test.go:16
Function
TestSetAsideKeepsTheWholeOpLog
(t *testing.T)
internal/store/task3574_set_aside_whole_test.go:35
Function
TestSetAsideMovesRowsAndMarksTheItem
(t *testing.T)
internal/store/bug3244_set_aside_test.go:44
Function
TestSetAsideOfAFlushedLogKeepsNothing
Control: with nothing unflushed, nothing is set aside and the item is clean.
internal/store/task3574_set_aside_whole_test.go:77
Function
TestSetAsideOverwriteDiscardsAndReports
(t *testing.T)
internal/server/bug3244_set_aside_guard_test.go:103
Function
TestSetAsideReadAndDiscardEndpoints
Ruling 3: the rows are readable as raw updates and an explicit discard clears the state without writing the body.
internal/server/bug3244_set_aside_guard_test.go:225
Function
TestSetAsideRefusesRestoreUntilOverwrite
(t *testing.T)
internal/server/bug3244_set_aside_guard_test.go:164
Function
TestSetAsideRefusesTokenedContentWrite
(t *testing.T)
internal/server/bug3244_set_aside_guard_test.go:91
Function
TestSetAsideRefusesTokenlessContentWrite
(t *testing.T)
internal/server/bug3244_set_aside_guard_test.go:67
Function
TestSetAsideRoundTripsThroughTheBundle
The bundle carries set-aside rows (condition a) and an import reattaches them, so the imported item reads the same state as its source.
internal/store/bug3244_set_aside_test.go:79
Function
TestSetAsideStaleNoticesNameTheRightRemedy
(t *testing.T)
cmd/pad/bug3244_set_aside_test.go:18
Function
TestSetAsideSurvivesCollabSnapshotFlush
The tab's own flush writes the new-era document; it is not replacing the set-aside edits (the body never held them), so it is not refused, and it must
internal/server/bug3244_set_aside_guard_test.go:126
Function
TestSetAsideSurvivesWatermarkStamp
A caught-up tab stamps the flush watermark (BUG-3124 unit B). That clears the unflushed-rows state by design; it must not clear the set-aside state, w
internal/server/bug3244_set_aside_guard_test.go:145
Function
TestSetIPChangeEnforce_CaseInsensitive
TestSetIPChangeEnforce_CaseInsensitive verifies the setter accepts common variants without surprises.
internal/server/middleware_session_ip_test.go:390
Function
TestSetMemberCollectionAccess_BackToAll
(t *testing.T)
internal/store/permissions_test.go:214
Function
TestSetMemberCollectionAccess_ReplaceGrants
(t *testing.T)
internal/store/permissions_test.go:182
Function
TestSetMemberCollectionAccess_RestrictedOwner_CrossMemberHiddenID_Forbidden
TestSetMemberCollectionAccess_RestrictedOwner_CrossMemberHiddenID_Forbidden pins the cross-member leak arm: a restricted owner cannot grant a DIFFEREN
internal/server/handlers_member_collection_access_escalation_test.go:73
Function
TestSetMemberCollectionAccess_RestrictedOwner_HiddenID_Forbidden
TestSetMemberCollectionAccess_RestrictedOwner_HiddenID_Forbidden pins the per-ID membership check: a restricted owner cannot include a collection outs
internal/server/handlers_member_collection_access_escalation_test.go:49
Function
TestSetMemberCollectionAccess_RestrictedOwner_ItemGrantOnly_StillForbidden
TestSetMemberCollectionAccess_RestrictedOwner_ItemGrantOnly_StillForbidden pins the fullCollIDs narrowing (mirrors requireCollectionFullyVisible, BUG-
internal/server/handlers_member_collection_access_escalation_test.go:130
Function
TestSetMemberCollectionAccess_RestrictedOwner_SelfToAll_Forbidden
TestSetMemberCollectionAccess_RestrictedOwner_SelfToAll_Forbidden pins the self-escalation arm: a restricted owner cannot PATCH their own record to mo
internal/server/handlers_member_collection_access_escalation_test.go:27
Function
TestSetMemberCollectionAccess_RestrictedOwner_WithinScope_OK
TestSetMemberCollectionAccess_RestrictedOwner_WithinScope_OK confirms a restricted owner can still manage collection access within their own visible s
internal/server/handlers_member_collection_access_escalation_test.go:104
Function
TestSetMemberCollectionAccess_UnrestrictedOwner_OK
TestSetMemberCollectionAccess_UnrestrictedOwner_OK confirms the guard is a no-op for an unrestricted (mode "all") owner — the common case.
internal/server/handlers_member_collection_access_escalation_test.go:148
Function
TestSetOrphanGCConfig_FloorsTheGraceAndSaysSo
(t *testing.T)
internal/server/task4280_locked_calls_bounded_test.go:157
Function
TestSetParentLink_ConcurrentNHopNoCycle
TestSetParentLink_ConcurrentNHopNoCycle exercises BUG-2074: an N-hop parent cycle closed via an edge on an item that NEITHER endpoint of a concurrent
internal/store/parent_link_concurrency_test.go:227
Function
TestSetParentLink_ConcurrentOpposingNoCycle
TestSetParentLink_ConcurrentOpposingNoCycle exercises BUG-2073 race 1: two goroutines run opposing SetParentLink(A,B) and SetParentLink(B,A) on the sa
internal/store/parent_link_concurrency_test.go:52
Function
TestSetParentLink_ConcurrentReparentSingleParent
TestSetParentLink_ConcurrentReparentSingleParent exercises BUG-2073 race 2: many goroutines reparent the SAME child to DIFFERENT parents at once. The
internal/store/parent_link_concurrency_test.go:130
Function
TestSetPlan_RejectsUnknownSource
(t *testing.T)
internal/server/handlers_plan_source_test.go:100
Function
TestSetPlan_StripeFreeDoesNotClobberManualPro
(t *testing.T)
internal/server/handlers_plan_source_test.go:62
Function
TestSetPlan_StripeFreeLowersStripePro
(t *testing.T)
internal/server/handlers_plan_source_test.go:86
Function
TestSetSSELimitsDoesNotStrandHeldSlots
TestSetSSELimitsDoesNotStrandHeldSlots covers reconfiguration while connections are held. Note the scope: SetSSELimits is config-time (see its doc com
internal/server/stream_admission_test.go:485
Function
TestSetSessionActivity
(t *testing.T)
internal/cli/client_session_activity_test.go:12
Function
TestSetSessionActivityTimeout
(t *testing.T)
internal/cli/client_session_activity_test.go:45
Function
TestSetTxTimeouts
(t *testing.T)
internal/store/runtime_pool_test.go:533
Function
TestSetUserPlan_ManualWriteFencesInFlightStripe
A manual decision fences a Stripe write already in flight: a fetch taken before the operator acted cannot land after and undo it. A fetch taken after
internal/store/bug3356_plan_revision_test.go:158
Function
TestSetUserPlan_MillisecondRevisions
Real revisions are unix milliseconds, beyond int4.
internal/store/bug3356_plan_revision_test.go:139
Function
TestSetUserPlan_NewUserIsManual
A new user starts free with source manual (the column default), which is what a caller that omits a source writes too.
internal/store/plan_source_test.go:126
Function
TestSetUserPlan_RefusesInvalidSourceAndMissingUser
(t *testing.T)
internal/store/plan_source_test.go:139
Function
TestSetUserPlan_RevisionOrdersStripeWrites
(t *testing.T)
internal/store/bug3356_plan_revision_test.go:24
Function
TestSetUserPlan_SourceRule
TASK-3295 / PLAN-3291 DR-6: a write that lowers a plan to free applies only from the source that set the plan (or when forced); every other write appl
internal/store/plan_source_test.go:12
Function
TestSetWorkspaceTool_AnnotationsExplicit
TestSetWorkspaceTool_AnnotationsExplicit pins pad_set_workspace's hand-written annotation block (BUG-2302): a session-state write — not read-only — bu
internal/mcp/catalog_annotations_test.go:90
Function
TestSetWorkspaceTool_BootstrapErrorFallsThrough
TestSetWorkspaceTool_BootstrapErrorFallsThrough verifies a bootstrap fetcher failure doesn't break the workspace switch. Agents can always retry the b
internal/mcp/workspace_test.go:205
Function
TestSetWorkspaceTool_EmbedsBootstrap
TestSetWorkspaceTool_EmbedsBootstrap verifies the response carries the structured bootstrap blob when a fetcher is supplied. PLAN-1377 TASK-1380 — pad
internal/mcp/workspace_test.go:158
Function
TestSetWorkspaceTool_EmptyStringClears
(t *testing.T)
internal/mcp/workspace_test.go:74
Function
TestSetWorkspaceTool_EmptyWorkspaceSkipsBootstrap
TestSetWorkspaceTool_EmptyWorkspaceSkipsBootstrap verifies that clearing the session default (workspace="") doesn't trigger a bootstrap fetch. Bootstr
internal/mcp/workspace_test.go:238
Function
TestSetWorkspaceTool_HandlerUpdatesState
(t *testing.T)
internal/mcp/workspace_test.go:52
Function
TestSetWorkspaceTool_MissingArgReturnsError
(t *testing.T)
internal/mcp/workspace_test.go:95
Function
TestSettleContentRouteBoundsTheStandoff
TestSettleContentRouteBoundsTheStandoff covers the decision the end-to-end tests cannot reach. The standoff state — a room whose only writer has join
internal/server/handlers_items_content_route_test.go:231
Function
TestSettleContentRouteStopsWhenTheCallerGoesAway
TestSettleContentRouteStopsWhenTheCallerGoesAway pins the only new blocking wait this change introduces. Without it a cancelled request keeps re-decid
internal/server/handlers_items_content_route_test.go:405
Function
TestSetupWriterRedactsCredentials
(t *testing.T)
internal/logging/redaction_test.go:15
Function
TestShareAssetDerive_FormatNormalization
Pin (c): format normalization — PNG source stays PNG (alpha survives), non-PNG (JPEG) normalizes to JPEG per ThumbnailFormat.
internal/server/handlers_share_attachments_derive_test.go:173
Function
TestShareAssetDerive_SmallImageRendersViaVariant
Pin (a): a ≤1024px image (the live 64×64 case) renders on a share page via a REAL derived variant — lazy-derived at resolve, no original ever served.
internal/server/handlers_share_attachments_derive_test.go:118
Function
TestShareAssetDerive_StripsEXIF
Pin (b): an EXIF-bearing source yields variant bytes with NO EXIF. Verify the BYTES, not intent.
internal/server/handlers_share_attachments_derive_test.go:146
Function
TestShareAssetSig_ExpTampered
(t *testing.T)
internal/server/handlers_share_attachments_test.go:73
Function
TestShareAssetSig_Expired
(t *testing.T)
internal/server/handlers_share_attachments_test.go:62
Function
TestShareAssetSig_RoundTrip
Tests for the share-link asset byte path (BUG-2389 2b / TASK-2637): GET /api/v1/s/{token}/attachments/{id}, variants-only, plus the signed-ref gate fo
internal/server/handlers_share_attachments_test.go:25
Function
TestShareAssetSig_ScopedToAttachment
(t *testing.T)
internal/server/handlers_share_attachments_test.go:38
Function
TestShareAssetSig_ScopedToLink
(t *testing.T)
internal/server/handlers_share_attachments_test.go:50
Function
TestShareAssetSig_UnconfiguredSecret
(t *testing.T)
internal/server/handlers_share_attachments_test.go:85
Function
TestShareAsset_ClaimSecretDoesNotKeyShareAssets
TestShareAsset_ClaimSecretDoesNotKeyShareAssets pins the TASK-2317 split: share-asset signing reads its own field, never the claim secret. Both are se
internal/server/handlers_share_attachments_test.go:543
Function
TestShareAsset_CollectionShareServesItemsInCollection
(t *testing.T)
internal/server/handlers_share_attachments_test.go:425
Function
TestShareAsset_ExpiredAndRevoked404
(t *testing.T)
internal/server/handlers_share_attachments_test.go:286
Function
TestShareAsset_ExpiredSignature404
(t *testing.T)
internal/server/handlers_share_attachments_test.go:368
Function
TestShareAsset_ItemShareRejectsForeignItemAttachment
--- anchoring & variants-only ------------------------------------------
internal/server/handlers_share_attachments_test.go:412
Function
TestShareAsset_NoVariantRow404
(t *testing.T)
internal/server/handlers_share_attachments_test.go:474
Function
TestShareAsset_OriginalVariantExcluded
(t *testing.T)
internal/server/handlers_share_attachments_test.go:461
Function
TestShareAsset_PlainMultiImageUnderMaxViews1
--- fork-1: plain links, max_views rides the page view -----------------
internal/server/handlers_share_attachments_test.go:224
Function
TestShareAsset_PlainServesThumbMdByDefault
(t *testing.T)
internal/server/handlers_share_attachments_test.go:261
Function
TestShareAsset_ProtectedRequireAuthAlsoGated
(t *testing.T)
internal/server/handlers_share_attachments_test.go:355
Function
TestShareAsset_ProtectedRequiresSignature
--- fork-2: protected links require a signed ref -----------------------
internal/server/handlers_share_attachments_test.go:324
Function
TestShareAsset_ProtectedWithoutSecretOmitsRef
--- mint-side: unconfigured secret degrades protected links ------------
internal/server/handlers_share_attachments_test.go:519
Function
TestShareAsset_SignatureForXDoesNotFetchY
(t *testing.T)
internal/server/handlers_share_attachments_test.go:384
Function
TestShareAsset_SoftDeletedAttachment404
(t *testing.T)
internal/server/handlers_share_attachments_test.go:447
Function
TestShareAsset_UnknownTokenAndAttachment404
(t *testing.T)
internal/server/handlers_share_attachments_test.go:502
Function
TestShareLinkAndGrantDeleteViews_NonOwner_403BeforeVisibility
─── Layering: requireMinRole (403) must run BEFORE visibility (404), ID-keyed delete/views handlers (BUG-1923) ────────────────────────── TestShareLin
internal/server/handlers_grant_visibility_test.go:781
Function
TestShareLinkViews_RestrictedOwner_HiddenTarget404
TestShareLinkViews_RestrictedOwner_HiddenTarget404 pins BUG-1923 for the view-history GET: handleShareLinkViews already resolved and workspace-scoped
internal/server/handlers_grant_visibility_test.go:542
Function
TestSharePageDoesNotImportCollab
TestSharePageDoesNotImportCollab is a regression guard for TASK-1266 (PLAN-1248 share-page read-only verification). The public share page at /s/{toke
internal/server/share_page_collab_isolation_test.go:35
Function
TestShellSplit_BasicCases
(t *testing.T)
internal/cmdhelp/example_validation_test.go:11
Function
TestShellSplit_UnterminatedQuotesError
(t *testing.T)
internal/cmdhelp/example_validation_test.go:37
Function
TestShortStateIsNotTruncated
(t *testing.T)
internal/decision/decision_test.go:634
Function
TestShorthandNamesSorted
(t *testing.T)
internal/schedule/shorthand_test.go:82
← previous
next →
24,401–24,500 of 28,840, ranked by callers