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
TestRunner_CancelledPassReleasesWithoutCountingAFailure
A pass that starts already cancelled claims nothing, calls nothing, and leaves the job owed with no attempt counted.
internal/decision/runner_test.go:335
Function
TestRunner_ClaimsOneJobAtATime
Jobs are claimed ONE AT A TIME, so a job's lease starts when its own evaluation starts. Claiming a whole pass up front let the last job wait out its l
internal/decision/runner_test.go:468
Function
TestRunner_CommentReevaluates
A comment changes the state (the trail is hashed), so it re-evaluates — the case items.seq alone would have missed.
internal/decision/runner_test.go:135
Function
TestRunner_DecisionsReadMarksCurrent
The read marks a row current only while its state is the item's state.
internal/decision/runner_test.go:209
Function
TestRunner_DeleteJustBeforeAskIsNotSent
Liveness is re-checked immediately before the provider call, so a delete landing between building the state and asking stops the send.
internal/decision/runner_test.go:505
Function
TestRunner_DeletedWorkspaceOrCollectionIsNeverSent
A soft-deleted WORKSPACE or COLLECTION stops evaluation even though the item row itself is live: nothing its owner deleted goes to the provider. A wor
internal/decision/runner_test.go:382
Function
TestRunner_FailureAndGoneItem
A failing provider leaves the job owed with the failure recorded, and a deleted item's job is dropped rather than retried.
internal/decision/runner_test.go:285
Function
TestRunner_HashedBytesAreTheBytesSent
ONE SERIALISATION PATH: the state bytes on the wire are byte-identical to the bytes hashed. The fixture's title and body carry <, >, & and U+2028, whi
internal/decision/runner_test.go:100
Function
TestRunner_NilProviderIsANoOp
Nil provider: no runner, no resolver, no job rows, and an empty read.
internal/decision/runner_test.go:239
Function
TestRunner_PermanentRefusalIsDroppedAfterRepeatedAttempts
(t *testing.T)
internal/decision/runner_test.go:603
Function
TestRunner_QuestionOrModelChangeReasks
An answer is current only for the QUESTION and MODEL that produced it. Rewording a question, or changing the pinned model, at an unchanged item state
internal/decision/runner_test.go:548
Function
TestRunner_RefusedFailureMessageStillCountsAndDrops
BUG-4022: an outcome the store refuses to record with the real message is still counted through runJob, so the permanent drop can fire. The store is p
internal/decision/runner_test.go:653
Function
TestRunner_RunOnceDrainsTheQueue
End to end through the queue: a write enqueues, one tick evaluates and retires the job, and a second tick finds nothing.
internal/decision/runner_test.go:266
Function
TestRunner_SetNoLongerApplicableAfterMoveIsNotAsked
A job owed for a set scoped to the item's OLD collection must not reach the provider after the item moves out of that collection.
internal/decision/runner_test.go:424
Function
TestRunner_StateInvisibleWritesDoNotReevaluate
Writes that change nothing the state carries move seq but must not cost a call: a role-board reorder, a parent-link add (the only link kinds that bump
internal/decision/runner_test.go:162
Function
TestRunner_TransientFailuresAreNeverDropped
A provider OUTAGE must not lose owed work. Transient failures (5xx, 429, transport) back off indefinitely; only a permanent refusal (a 4xx naming the
internal/decision/runner_test.go:586
Function
TestRunner_UnchangedStateShortCircuits
Idempotency: an unchanged state makes no second call.
internal/decision/runner_test.go:122
Function
TestRunner_WorkspaceDeletedMidJobIsHeld
M35: a workspace deleted between the claim and the send, through RunOnce — the job is HELD (owed, unclaimed, no attempt), not dropped.
internal/decision/runner_test.go:634
Function
TestRunner_WorkspaceRestoreResumesHeldWork
Work owed in a workspace that is soft-deleted and then RESTORED is evaluated after the restore — nothing enqueues on restore (it is a fan-out), so the
internal/decision/runner_test.go:523
Function
TestRuntimeLimits_applyToDSN
(t *testing.T)
internal/store/runtime_pool_test.go:645
Function
TestRuntimePool_EveryConnBounded
(t *testing.T)
internal/store/runtime_pool_test.go:221
Function
TestRuntimePool_IdleInTxTerminated
(t *testing.T)
internal/store/runtime_pool_test.go:158
Function
TestRuntimePool_LockTimeout
(t *testing.T)
internal/store/runtime_pool_test.go:118
Function
TestRuntimePool_StatementTimeoutCancels
(t *testing.T)
internal/store/runtime_pool_test.go:88
Function
TestSQLiteConcurrentWritersNoBusy
TestSQLiteConcurrentWritersNoBusy guards against the BUG-748-followup regression where Go's default deferred-mode transactions returned SQLITE_BUSY im
internal/store/store_test.go:432
Function
TestSQLiteDialect
(t *testing.T)
internal/store/dialect_test.go:68
Function
TestSQLiteException
(t *testing.T)
scripts/ci-web-census/main_test.go:76
Function
TestSSEAccessEpochAdvance_DegradedSnapshotNeitherAnnouncesNorMovesTheBase
TestSSEAccessEpochAdvance_DegradedSnapshotNeitherAnnouncesNorMovesTheBase covers the degraded-snapshot case. A snapshot resolved through a store fault
internal/server/bug3347_access_epoch_effective_test.go:166
Function
TestSSEAfterBusCloseIsRefusedNotHeld
TestSSEAfterBusCloseIsRefusedNotHeld is BUG-2737's BINDING assertion (CONVE-19): internal/events vouches for a closed bus refusing a subscribe; this p
internal/server/handlers_events_failed_test.go:103
Function
TestSSEConnectedEvent
(t *testing.T)
internal/server/handlers_events_test.go:127
Function
TestSSEDocumentArchivedAndRestoredEvents
(t *testing.T)
internal/server/handlers_events_test.go:217
Function
TestSSEDocumentCreatedEvent
(t *testing.T)
internal/server/handlers_events_test.go:150
Function
TestSSEDocumentUpdatedEvent
(t *testing.T)
internal/server/handlers_events_test.go:184
Function
TestSSEEntryRequiresMembership
TestSSEEntryRequiresMembership is the TASK-264 regression: the SSE entry gate must reject an authenticated NON-member for BOTH the ?workspace=<slug> a
internal/server/handlers_events_membership_test.go:32
Function
TestSSEEventVisibleFor
TestSSEEventVisibleFor covers the visibility matrix: - itemless batch events (items_bulk_updated, TASK-1668) are suppressed for item-grant-only subscr
internal/server/handlers_events_filter_test.go:16
Function
TestSSEGlobalConnectionLimit
(t *testing.T)
internal/server/handlers_events_test.go:372
Function
TestSSEKeepaliveIdleTimeoutInvariant
TestSSEKeepaliveIdleTimeoutInvariant is a belt-and-suspenders check for the relationship enforced by handlers_events.go's init() guard. If this assert
internal/server/handlers_events_test.go:531
Function
TestSSELimitsExistingConnectionsUnaffected
(t *testing.T)
internal/server/handlers_events_test.go:440
Function
TestSSEMembershipRevalInterval_DefaultsToSensibleCadence
TestSSEMembershipRevalInterval_DefaultsToSensibleCadence pins the default tick interval. Not functional on its own; it's a guard so a future cleanup d
internal/server/handlers_events_revalidation_test.go:303
Function
TestSSEMissingWorkspace
Error case tests use doRequest since they return immediately
internal/server/handlers_events_test.go:345
Function
TestSSEMissingWorkspaceParam
(t *testing.T)
internal/server/handlers_events_test.go:354
Function
TestSSEMultipleClients
(t *testing.T)
internal/server/handlers_events_test.go:254
Function
TestSSENoEventBus
(t *testing.T)
internal/server/handlers_events_test.go:363
Function
TestSSEPerWorkspaceLimit
(t *testing.T)
internal/server/handlers_events_test.go:402
Function
TestSSEStream_AnnouncesAnAccessChangeButStaysQuietOtherwise
TestSSEStream_AnnouncesAnAccessChangeButStaysQuietOtherwise is the WIRING half of IDEA-2898's server signal (CONVE-19): the epoch's correctness is pin
internal/server/handlers_events_access_epoch_stream_test.go:32
Function
TestSSEStream_ClosesWhenItsWorkspaceIsSoftDeleted
TestSSEStream_ClosesWhenItsWorkspaceIsSoftDeleted is the same question asked through the router on a live server: a member's open stream answers `unau
internal/server/bug3273_stream_soft_delete_test.go:80
Function
TestSSESubscriberCleanup
(t *testing.T)
internal/server/handlers_events_test.go:315
Function
TestSSESubscriberStillHasAccess
TestSSESubscriberStillHasAccess verifies the per-tick membership revalidation helper returns the right answer across all supported access paths: admin
internal/server/handlers_events_revalidation_test.go:18
Function
TestSSESubscriberStillHasAccess_AdminBearer_DeniedEvenWithGrants
TestSSESubscriberStillHasAccess_AdminBearer_DeniedEvenWithGrants pins the membership-only stance: a bearer-admin with a guest grant on a workspace the
internal/server/handlers_admin_bearer_gate_test.go:95
Function
TestSSESubscriberStillHasAccess_AdminBearer_DeniedOnNonMember
TestSSESubscriberStillHasAccess_AdminBearer_DeniedOnNonMember pins the bearer-aware revalidation path. Cookie admin → still has access; bearer admin (
internal/server/handlers_admin_bearer_gate_test.go:56
Function
TestSSESubscriberStillHasAccess_AdminDemotion
TestSSESubscriberStillHasAccess_AdminDemotion verifies that an admin who is demoted to "member" AFTER the SSE connection was established loses access
internal/server/handlers_events_revalidation_test.go:186
Function
TestSSESubscriberStillHasAccess_SoftDeletedWorkspace
BUG-3273: an open workspace stream (GET /api/v1/events) survived a soft delete of its workspace. The entry check refuses a deleted workspace, but the
internal/server/bug3273_stream_soft_delete_test.go:24
Function
TestSSEVisibilityAccessEpoch_TracksNarrowingAndMatchesTheItemDoors
TestSSEVisibilityAccessEpoch_TracksNarrowingAndMatchesTheItemDoors covers the two things the 60s revalidation tick's sync_required emission rests on (
internal/server/handlers_events_access_epoch_test.go:27
Function
TestSSEWorkspaceIsolation
(t *testing.T)
internal/server/handlers_events_test.go:287
Function
TestSSE_BUG3637_StalledReaderReleasesItsSlot
(t *testing.T)
internal/server/bug3637_sse_stalled_reader_test.go:218
Function
TestSSE_BUG3637_WriteTimeoutOutlastsTheKeepaliveCadence
The production write deadline must outlast the keepalive cadence by a stated margin, twice, on both streams (BUG-3637): the stalled-reader tests use a
internal/server/bug3637_sse_stalled_reader_test.go:337
Function
TestSSE_BUG3637_WriterWithoutDeadlineIsRefused
A writer that cannot take a write deadline is refused before anything is streamed or subscribed: the frames could not be bounded (BUG-3637). httptest.
internal/server/bug3637_sse_stalled_reader_test.go:261
Function
TestSSE_TASK2197_HeartbeatIsOptIn
(t *testing.T)
internal/server/task2197_sse_heartbeat_test.go:52
Function
TestSSE_TASK2197_HeartbeatsArriveOnABusyStream
A heartbeat must arrive while events are flowing faster than the keepalive interval: a ticker that every event write RESET would fire only after a ful
internal/server/task2197_sse_heartbeat_test.go:85
Function
TestSafeLocalFilename
safeLocalFilename builds a LOCAL path component out of a remote string, so its contract is what keeps `pad attachment view` from writing outside its t
cmd/pad/cmd_attachment_filename_test.go:13
Function
TestSafeLocalFilenameFor_BUG3186
BUG-3186: the CLI applies the Windows path rule only when it runs on Windows. On Linux and macOS the served name is kept, since a colon is legal there
cmd/pad/attachment_local_name_test.go:13
Function
TestSafeLocalFilename_FollowsHostOS_BUG3186
The binding leg, driven through the PRODUCTION wrapper under each OS. A wrapper that ignores hostOS (hard-coding "windows" or "linux") gives the same
cmd/pad/attachment_local_name_test.go:42
Function
TestSameFilePathIdentifiesTheServersDatabase
TestSameFilePathIdentifiesTheServersDatabase covers the comparison the running-server guard is built on. The guard used to be skipped whenever --from
cmd/pad/cmd_db_nul_test.go:183
Function
TestSameServerURL
(t *testing.T)
cmd/pad/task3612_link_repoint_test.go:166
Function
TestSameWorkspaceMoveKeepsTheSchedule
A move into another collection of the SAME workspace keeps the schedule and its managed row untouched.
internal/store/schedule_copy_test.go:301
Function
TestSanitizeFTSQuery
TestSanitizeFTSQuery is a unit test for the helper that wraps each token in double quotes so SQLite FTS5 treats special characters as literals. See in
internal/store/items_test.go:2197
Function
TestSanitizeHeaderFilename_DropsExactlyTheIngestPredicate
The header and ingest drop EXACTLY the same characters, over every rune. This is the invariant for BUG-2818 as a test: a sanitiser with its own charac
internal/server/handlers_attachments_bug2818_test.go:260
Function
TestSanitizeMarkdownText_StripsNonSGRSequences
The markdown path promises no ANSI in its output; that promise has to hold for non-SGR sequences too.
internal/cli/format_ansi_test.go:65
Function
TestSanitizePGFTSQuery
TestSanitizePGFTSQuery is a unit test for the BUG-842 helper that produces the second leg of the OR-combined PG FTS query (raw + hyphen-as-space). See
internal/store/items_test.go:2169
Function
TestSanitizeSessionLabel
(t *testing.T)
internal/server/session_identity_test.go:10
Function
TestSanitizeSessionLabel_TruncatesByRunes
TestSanitizeSessionLabel_TruncatesByRunes pins the bound as RUNES, not bytes. A byte-based cap would slice a multibyte character in half and emit inva
internal/server/session_identity_test.go:52
Function
TestSanitizeVersion
(t *testing.T)
internal/store/migration_guard_test.go:223
Function
TestSaveAndLoadRoundTrip
(t *testing.T)
internal/config/config_test.go:10
Function
TestSavePreservesPushVetoForStrictLoader
TestSavePreservesPushVetoForStrictLoader guards PLAN-2613 S2's consent path: a per-user auto_arm=false veto written by Save() must survive an atomic w
internal/config/config_test.go:60
Function
TestScanAndRepairAgreeThroughTheCommandPath
TestScanAndRepairAgreeThroughTheCommandPath drives the store API the two commands call, so the CLI's promise — scan-nul is the dry run for repair-nul
cmd/pad/cmd_db_nul_test.go:94
Function
TestScanAndRepairInvalidUTF8
(t *testing.T)
internal/store/nulutf8_test.go:21
Function
TestScanBracketBodyAgreesWithTheParser
TestScanBracketBodyAgreesWithTheParser pins the third half of BUG-2805, which the repro did not name. The rewriter used strings.Index(rest, "]]") to
internal/links/rewrite_brackets_diff_test.go:754
Function
TestScanBracketBodyEdgeCasesMatchTheParser
TestScanBracketBodyEdgeCasesMatchTheParser locks the delimiter edges down against the parser as oracle, one assertion per shape. The parity property
internal/links/rewrite_brackets_diff_test.go:831
Function
TestScanCostFiguresMatchTheList
TestScanCostFiguresMatchTheList keeps ScanNUL's doc comment honest. That comment tells an operator how much work the scan is — one unindexed scan per
internal/store/nulscan_test.go:336
Function
TestScanNULDetectsEveryRefusedJSONCorpusCase
TestScanNULDetectsEveryRefusedJSONCorpusCase plants each JSON-classed case the shared corpus says must be REFUSED into items.fields and asserts the sc
internal/store/nulscan_test.go:559
Function
TestScanNULFindsThePlantedPopulation
TestScanNULFindsThePlantedPopulation drives every shape the counter has to tell apart, including the two it must NOT report.
internal/store/nulscan_test.go:50
Function
TestScanNULOnPostgresSaysWhyItDidNotLook
TestScanNULOnPostgresSaysWhyItDidNotLook guards the one thing a zero report must never be mistaken for.
internal/store/nulscan_test.go:300
Function
TestScanNULReportsNoAcceptedCorpusCase
TestScanNULReportsNoAcceptedCorpusCase is the other direction of TestScanNULDetectsEveryRefusedJSONCorpusCase: a JSON-classed corpus case every layer
internal/store/nulscan_test.go:729
Function
TestScanNULReportsOnlyViolations
TestScanNULReportsOnlyViolations covers the two values the deleted SUSPECT class was built around (BUG-3220): pre-filter matches whose meaning the pre
internal/store/nulscan_test.go:610
Function
TestScanNULSurvivesANullWorkspaceID
TestScanNULSurvivesANullWorkspaceID is a regression test for a scan that could not run on the databases it exists for. Several protected tables carry
internal/store/nulscan_test.go:435
Function
TestScannerAcceptsWhatEncodingJSONAccepts
The scanner's acceptance must be encoding/json v1's, or a check built on it answers about documents the typed decode reads differently. The oracle is
internal/jsonscan/jsonscan_test.go:33
Function
TestScannerDecodesStringsAndKeepsRepeats
Strings come back DECODED, keys included, and every occurrence of a repeated key arrives.
internal/jsonscan/jsonscan_test.go:74
Function
TestScannerMalformedIsErrMalformed
(t *testing.T)
internal/jsonscan/jsonscan_test.go:85
Function
TestScannerReadsALoneSurrogateAsV1Does
A lone surrogate is v1's U+FFFD, not a malformed document: a scanner that called it malformed made the whole body report nothing, so a NUL beside it p
internal/jsonscan/jsonscan_test.go:62
Function
TestScheduleAckBundleRoundTrip
(t *testing.T)
internal/store/schedule_ack_test.go:303
Function
TestScheduleAckBundleValidationAndFreshCopy
(t *testing.T)
internal/store/schedule_ack_test.go:329
Function
TestScheduleAckMigrationPreservesJournal
(t *testing.T)
internal/store/schedule_ack_migration_test.go:8
Function
TestScheduleActiveBulkUpdate
(t *testing.T)
internal/server/handlers_items_schedule_active_test.go:121
Function
TestScheduleActiveExceptions
(t *testing.T)
internal/server/handlers_items_schedule_active_test.go:57
Function
TestScheduleActiveGuardOrder
(t *testing.T)
internal/server/handlers_items_schedule_active_test.go:96
Function
TestScheduleActivePreservesCodeAndDetails
(t *testing.T)
internal/mcp/open_children_passthrough_test.go:460
Function
TestScheduleActiveRDateOneShot
An RDATE that repeats the start, or is excluded, adds no second occurrence, so the schedule is still a one-shot and closing is not refused.
internal/server/handlers_items_schedule_active_test.go:266
Function
TestScheduleActiveRDateOnly
TASK-4601: a schedule with RDATEs and no RRULE still has future occurrences, so closing its item is refused the same way an RRULE schedule is.
internal/server/handlers_items_schedule_active_test.go:234
Function
TestScheduleActiveReopenResumesAgenda
(t *testing.T)
internal/server/handlers_items_schedule_active_test.go:140
Function
TestScheduleActiveUpdate
(t *testing.T)
internal/server/handlers_items_schedule_active_test.go:20
← previous
next →
24,001–24,100 of 28,840, ranked by callers