Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
207 commits
Select commit Hold shift + click to select a range
69196d6
007 S007-10+15: Tests 1 and 2 with the shape module, and tests 5, 6 a…
brettheap Nov 15, 2026
8ff07b5
P07 follow-up 1: T273k, lane 2's change to the partitioned_estate fix…
brettheap Nov 15, 2026
a8e3394
007 S007-06+13+19+20+25: The guard's direct read and phase-N cases, t…
brettheap Nov 15, 2026
366e62f
P09 follow-up 1: T229g, lane 2's fixture gate table, on lane 3's ruli…
brettheap Nov 15, 2026
492620a
P09 follow-up 2: T254zx, lane 2's measure row, the M9 [files] id that…
brettheap Nov 15, 2026
9f6579d
P09 follow-up 3: T224i, lane 2's managed row, tls_at_load's [journal-…
brettheap Nov 15, 2026
8192451
T273j: Read REGISTER_SCHEMA_VERSION from T124's module beside the fli…
brettheap Nov 15, 2026
4e9821a
T273l: Drop each rollback fixture's database whatever ends its build,…
brettheap Nov 15, 2026
f047f76
T227d: Say in _test7_seed's docstring that the seed is T211's SEED bu…
brettheap Nov 15, 2026
0e40a16
T237zzi: End the guard module on its last assert, with no blank line …
brettheap Nov 15, 2026
5109125
T257o: Name each writer, journal row and commit call when the burst t…
brettheap Nov 15, 2026
f4f0ebc
T257p: Push a STORE-only marker commit to the bench's origin in Bench…
brettheap Nov 15, 2026
51aae86
T270o: End a renderer that never reached its held push with its proce…
brettheap Nov 16, 2026
c15c1f3
T273m: Drop RollbackRegister's database whatever ends any step of its…
brettheap Nov 16, 2026
4051ec7
T270m: Own every launcher and FIFO end in RenderEstate.race with a fi…
brettheap Nov 16, 2026
c2c7530
T273o: Kill the rollback that never reached its held push, let the FI…
brettheap Nov 16, 2026
21855bb
T224j: Hide each password-file line's password in the managed module'…
brettheap Nov 16, 2026
e090913
T224k: Mark the managed module PYTEST_DONT_REWRITE, so no assertion's…
brettheap Nov 16, 2026
4e76dbd
T255i: Make M13 fail where a path that connected sent no Query messag…
brettheap Nov 16, 2026
f85945f
T237zzl: Stop the bounds bench's service by its process group, with K…
brettheap Nov 16, 2026
8907fc7
T257q: End and reap every burst writer when anything ends the burst's…
brettheap Nov 16, 2026
881ac5f
T237zzm: Stop M13's [m5] service by its process group, with KILL and …
brettheap Nov 16, 2026
b27e776
T255j: Stop the guard read's stand-in pid with bounded waits, as M13'…
brettheap Nov 16, 2026
6f34986
T255k: Give the relay shapes' held-session wait a monotonic deadline …
brettheap Nov 16, 2026
6c34607
T257r: Hold the burst to one journal row for each writer that exited …
brettheap Nov 16, 2026
56706e4
T274f: Hold AT-F18's replacement to one commit call carrying the new …
brettheap Nov 16, 2026
01a8873
T220o: Register, start and close the bounds relays' sockets and pumps…
brettheap Nov 16, 2026
8aa33be
T278h: Register and start ArmedFault's held sockets and pumps under t…
brettheap Nov 16, 2026
571c627
T215n: Register, start and close the outage relay's sockets and pumps…
brettheap Nov 16, 2026
28f11b9
T224l: Make each failing check-11 case name the fault it is built to …
brettheap Nov 16, 2026
178f46c
T274g: Hold the restore's second bootstrap to the complete object inv…
brettheap Nov 16, 2026
c69dd3f
T229h: Keep a TLS cluster's port on a restart, and raise a restart's …
brettheap Nov 16, 2026
fe1c8ba
T270n: Release the held burst's render only once at least four forks …
brettheap Nov 16, 2026
a8446eb
T241m: Run the pending hand edit's recovery command split by shlex wi…
brettheap Nov 16, 2026
fec6b59
T241n: Require the pending hand edit's recovery command to restore ex…
brettheap Nov 16, 2026
973a2ed
T270p: Own each held renderer to the end, unlink a let-go FIFO, close…
brettheap Nov 16, 2026
6d47941
T273p: Own the held rollback to the end in the marker-removal case, l…
brettheap Nov 16, 2026
8abda6e
T255l: Reap the relay shapes' held session in the case's own clean-up…
brettheap Nov 17, 2026
4363541
T224m: Keep SCRAM verifiers out of the managed module's failure messa…
brettheap Nov 17, 2026
e805611
T230c: Bound hook_pid's reap of the stand-in it kills, and kill and r…
brettheap Nov 17, 2026
a3a4643
T215o: Bound AT-F7's reaps of the stand-ins they kill, and kill and r…
brettheap Nov 17, 2026
21dd364
T258d: Keep the SCRAM verifier out of the membership-only revoke's fa…
brettheap Nov 17, 2026
61cbdf1
T270q: Let every hold FIFO go by unlinking it before its last write e…
brettheap Nov 17, 2026
f31f8c0
T273q: Tear down every rollback case through one helper that kills it…
brettheap Nov 17, 2026
18529e5
T241o: Require the pending hand edit's refusal to exit 2, with nothin…
brettheap Nov 17, 2026
12cd187
T241p: Forbid a printed `lanes-edit.sh commit` in the pending hand ed…
brettheap Nov 17, 2026
c53e5ac
T237zzn: Signal the bounds bench's processes only while they are unre…
brettheap Nov 17, 2026
7237a92
T237zzo: Signal M13's process groups only while their leaders are unr…
brettheap Nov 17, 2026
227de0a
T237zzw: Close the guard listener's sockets only once its thread has …
brettheap Nov 17, 2026
d28a7c3
T237zzx: Test that the bench's clean-up signals only an unreaped proc…
brettheap Nov 17, 2026
779b216
T237zzy: Test that M13's group clean-up signals only an unreaped lead…
brettheap Nov 17, 2026
6b0f9bb
T255m: Keep and join the held session's readers, and raise its reap a…
brettheap Nov 17, 2026
970b501
T257t: Start each writer in a session of its own and end it with its …
brettheap Nov 17, 2026
66ce53e
T270r: Signal clean-up processes only through pidfds pinned to their …
brettheap Nov 17, 2026
ae408cd
T273r: Signal the rollback teardown's processes only through pidfds p…
brettheap Nov 17, 2026
e1934c3
T224n: Require each failing check-11 case's own fault by a predicate,…
brettheap Nov 17, 2026
ab78121
T258e: Reap phase W's writers in the main thread, end a writer's grou…
brettheap Nov 17, 2026
ca77405
T224o: Read _run's terminal and stderr, and a held session's two pipe…
brettheap Nov 17, 2026
c97d4a1
T219k: Take the password-absence cases' oracles as bools, and quote t…
brettheap Nov 17, 2026
c963509
T215p: Track AT-F7's relay sockets before a bounded connect, shut the…
brettheap Nov 17, 2026
ddf9d43
T220p: Track the bounds relays' sockets before a bounded connect, shu…
brettheap Nov 17, 2026
bc74872
T278i: Relay ArmedFault's unheld connections through StartupRelay's t…
brettheap Nov 17, 2026
d3a2fd5
T229i: Track the silent relay's sockets before a bounded connect, sta…
brettheap Nov 17, 2026
46cac74
T273s: Seek each process the rollback teardown owns as its pid and st…
brettheap Nov 17, 2026
579b191
T258f: Leave a phase-W writer unreaped until its group is ended, its …
brettheap Nov 17, 2026
5df6dc8
T224p: Require the hung run's child gone 3 s before its own watchdog,…
brettheap Nov 17, 2026
a19b947
T219m: Carry T121 in each of T219's own rows of the outage gate table
brettheap Nov 17, 2026
182fa56
T215r: Drop the outage gate table's wildcard row, carrying T121 in T2…
brettheap Nov 17, 2026
ed0bef2
T270s: Own each clean-up process by a launch nonce in its environment…
brettheap Nov 17, 2026
9de78cb
T257u: Assert the under-2 refusal names its key and minimum and shows…
brettheap Nov 17, 2026
f776b43
T273t: Own each rollback teardown process by a launch nonce in its en…
brettheap Nov 17, 2026
16a4554
T257v: Print each burst writer's WARNING whole and a failed writer's …
brettheap Nov 17, 2026
f89210a
T258g: Join a phase-W writer's reader and close its pipes in a finall…
brettheap Nov 17, 2026
e484f2a
T224q: Run T224o's terminal case on Linux alone, since its stand-in f…
brettheap Nov 17, 2026
bb89fac
T257w: End the lookup-wait and delayed-link writers in a finally, and…
brettheap Nov 17, 2026
16dcded
T220q: Say that CONNECT_WAIT bounds the bounds relays' upstream conne…
brettheap Nov 17, 2026
d3eb548
T215s: Say that CONNECT_WAIT bounds AT-F7's relay's upstream connect,…
brettheap Nov 17, 2026
99def20
T229j: Say that CONNECT_WAIT bounds the silent relay's upstream conne…
brettheap Nov 17, 2026
51484a1
T255n: Join a held session's readers and close its pipes even where i…
brettheap Nov 17, 2026
b8f9e35
T237zzza: Close a socket the guard listener accepts once its stop is …
brettheap Nov 17, 2026
035c336
T270t: Keep the clean-up engine renderer_git and rollback share in on…
brettheap Nov 17, 2026
071f978
T273u: Import the shared clean-up engine from tests/sql_register_clea…
brettheap Nov 17, 2026
d34c7ea
T270u: Make the clean-up engine's group discovery, pidfd ownership an…
brettheap Nov 17, 2026
5a12064
T273v: Put the case's nonce on every rollback launch before the first…
brettheap Nov 17, 2026
c2049c0
T257x: Print only each burst writer's exit and WARNING lines, and no …
brettheap Nov 17, 2026
6f8fce1
T255o: Have each held-session reader close its own stream in a finall…
brettheap Nov 17, 2026
d7e46f5
T255p: Keep a held session's kill error and still try its bounded reap
brettheap Nov 17, 2026
21fe956
T224r: Read the clock after each look before the hung run's child cou…
brettheap Nov 17, 2026
f709b8c
T257y: Bound T257w's regression's wait for its marks, naming each sta…
brettheap Nov 17, 2026
4aa3025
T258h: Make phase W's reader cancellable with a bounded poll, close i…
brettheap Nov 17, 2026
58a65df
T258i: Count T258f's descendant gone only where it is seen before the…
brettheap Nov 17, 2026
6698834
T258j: Hold T258g's stand-in on a FIFO barrier released at the signal…
brettheap Nov 17, 2026
e41c2c7
T257z: Run T257w's regression on Linux alone, with T224q's skip, sinc…
brettheap Nov 17, 2026
96decfc
T257za: Share one communicate-and-end helper, _communicated, between …
brettheap Nov 17, 2026
26d4e85
T257zb: Refuse T257u's case value as a token of its own in the under-…
brettheap Nov 17, 2026
b96ff01
T273w: Read the left process's stat once a pass in the construction-f…
brettheap Nov 17, 2026
7b4b45d
T270v: Make the clean-up's stop, kill, confirm and read-again one loo…
brettheap Nov 17, 2026
1b6d25e
T273x: Run rollback's teardown steps 1 and 5 on the clean-up's one lo…
brettheap Nov 17, 2026
c2371be
T273y: State the rule of RollbackEstate's environment window: while i…
brettheap Nov 17, 2026
fb359e6
T258k: Release T258g's barrier at the reader's first join, not at the…
brettheap Nov 17, 2026
73279c1
T270w: Split the clean-up's one loop into a class whose steps each st…
brettheap Nov 17, 2026
e5aa44e
T270x: Wait for the child's environment to carry the nonce before the…
brettheap Nov 17, 2026
464f7f3
T270y: Show the stop-forks model's late member only once its parent i…
brettheap Nov 17, 2026
bb190f7
T270z: Wait for each child's environment to carry the nonce before th…
brettheap Nov 17, 2026
546eb5a
T257zc: Show a writer's WARNING line only where it matches a template…
brettheap Nov 17, 2026
b11fa88
T255q: Chain the reap's error, then the first clean-up failure, under…
brettheap Nov 17, 2026
2407ea0
T257zd: Match each WARNING template in time linear in the line, and m…
brettheap Nov 17, 2026
7fdb1aa
T257ze: End the shown seq of the in-register WARNING at the product's…
brettheap Nov 17, 2026
c5e9278
T255r: Chain every clean-up failure of a held session's end, not only…
brettheap Nov 17, 2026
84c5276
T273z: Wait for each child's environment to carry the nonce before th…
brettheap Nov 17, 2026
e870427
T257zf: Take the pending record's register generation as a UUID, so t…
brettheap Nov 17, 2026
a15d1c0
T257zg: Say in the two burst-report regressions' docstrings what each…
brettheap Nov 17, 2026
4789068
T270za: Check the one loop's deadline right after each read, before i…
brettheap Nov 17, 2026
3267d6d
T270zb: Keep every error the git wrapper's kill meets, and raise the …
brettheap Nov 17, 2026
08b4a81
T257zh: Show a writer's output in bounds' failure messages only throu…
brettheap Nov 17, 2026
e5f73a8
T255s: Show a writer's output in measure's failure messages only thro…
brettheap Nov 17, 2026
d45d17c
T258l: Show a writer's output in managed's failure messages only thro…
brettheap Nov 17, 2026
d9a1f2b
T257zi: Fail, by file and line, any failure message in bounds, measur…
brettheap Nov 17, 2026
4d4bf03
T255t: Opt measure out of pytest's assertion rewriting, so a failed a…
brettheap Nov 17, 2026
a1e99a5
T257zj: Opt bounds out of pytest's assertion rewriting, and fail the …
brettheap Nov 17, 2026
d29f463
T255u: Show swapped's listed lanes in a failure message only where ea…
brettheap Nov 17, 2026
be88b3c
T273za: Wait for the logged push's environment to carry the nonce, an…
brettheap Nov 17, 2026
3bb1265
T270zc: Wait for the logged renderer's environment to carry the nonce…
brettheap Nov 17, 2026
d7bf6f3
T229k: Show no line of psql's text in Cluster.psql's ClusterError, on…
brettheap Nov 17, 2026
cab8fcf
T270zd: Make the one loop's deadline error true where its last pass c…
brettheap Nov 17, 2026
f00ffda
T257zk: Fail where a failed psql's ClusterError holds any line of psq…
brettheap Nov 17, 2026
b99d587
T255v: Show a held psql session's stderr in _ask's failure only throu…
brettheap Nov 17, 2026
1222ee2
T258m: Show no line of pg_restore's output or of the server log's sta…
brettheap Nov 17, 2026
3d82630
T255w: Parse measure's whole numbers from output with an error that q…
brettheap Nov 17, 2026
e63e7aa
T257zl: Parse bounds' numbers from psql's output with an error that q…
brettheap Nov 17, 2026
8622aa0
T258n: Parse managed's committed seq from a writer's output with an e…
brettheap Nov 17, 2026
5c3ffef
T255x: Exercise [reader-left]'s clean-close form again, as a new para…
brettheap Nov 17, 2026
0bbf041
T257zm: Show an exit in _said_safely only where it is an int, and let…
brettheap Nov 17, 2026
0138949
T255y: Show the writer's exit in each measure message that gave _said…
brettheap Nov 17, 2026
d5c442b
T258o: Show the exit in each managed message that gave _said_safely a…
brettheap Nov 17, 2026
fab07bc
T257zn: Show the exit in each bounds message that gave _said_safely a…
brettheap Nov 17, 2026
d5ce1bd
T257zo: Parse bounds' last three numbers from output with _whole, quo…
brettheap Nov 17, 2026
e6643fc
T258p: Parse managed's stand-in pids from their mark files with _whol…
brettheap Nov 17, 2026
3f9fcac
T257zp: Make the static check see a stream copied into a name, .errs,…
brettheap Nov 17, 2026
08f3e4e
T258q: Show the exit, or say there is none, in managed's messages tha…
brettheap Nov 17, 2026
3c5b68b
T257zq: Show the exit in bounds' messages that gave _said_safely a na…
brettheap Nov 17, 2026
073afa2
T205e: Print short tracebacks wherever --tb is still pytest's default…
brettheap Nov 17, 2026
2475cfc
T257zr: Raise _whole's error after its except, so no ValueError quoti…
brettheap Nov 17, 2026
09e51bb
T255z: Raise measure's _whole error after its except, so no ValueErro…
brettheap Nov 17, 2026
a3fd173
T255za: Label _ask's held-session stderr as stderr in its failure mes…
brettheap Nov 17, 2026
49e2563
T257zs: Show a store error that the code under test raised as its cla…
brettheap Nov 17, 2026
1bf25c0
T257zt: Render pytest's own report of four bounds failures whose fram…
brettheap Nov 17, 2026
58d05e8
T257zu: Give a failed psql the password statement it echoes, and find…
brettheap Nov 17, 2026
385c547
T255zb: Render pytest's own report of measure's swapped check and hel…
brettheap Nov 17, 2026
ac229b9
T258r: Render pytest's own report of managed's two password checks fa…
brettheap Nov 17, 2026
61db3c5
T257zv: Fail where conftest's hook leaves pytest's default --tb=auto,…
brettheap Nov 17, 2026
d516068
T258s: Say a held session's real exit, or that its psql still runs, i…
brettheap Nov 17, 2026
aa4c32b
T258t: Name no login in _passwords' failure, only how many logins wer…
brettheap Nov 17, 2026
161c308
T255zc: Show the read's own exit, not only the last warming read's, i…
brettheap Nov 17, 2026
7f23288
T257zw: Give [timed-out-writer]'s planted writer 2 s, not 5, and say …
brettheap Nov 17, 2026
72497d8
T257zx: Make its_exit an int or None that the helper shows, not free …
brettheap Nov 17, 2026
5d31781
T229l: Show only the server log's counts in a failed start's or stop'…
brettheap Nov 17, 2026
e0ace78
T257zza: Fail where a failed start's or stop's ClusterError, or pytes…
brettheap Nov 17, 2026
2072e8c
T229m: Show only exits and counts of initdb's, lanes-index's, git's, …
brettheap Nov 17, 2026
d0b83cc
T257zzb: Fail where a failed tool's error in pgcluster, or pytest's r…
brettheap Nov 17, 2026
fde81e2
T229n: Count, never quote, a psql answer pgcluster did not expect: pg…
brettheap Nov 17, 2026
3ed57d0
T257zzc: Fail where a psql answer pgcluster did not expect, or pytest…
brettheap Nov 17, 2026
41b3e45
T229o: Show no text a tool printed in the engine probe's problem: a -…
brettheap Nov 17, 2026
d0afee7
T257zzd: Fail where the engine probe's problem, or pytest's report of…
brettheap Nov 17, 2026
6deff66
T229p: Take Cluster.psql's SQLSTATE only from psql's verbose form on …
brettheap Nov 17, 2026
882c497
T257zze: Fail where a failed psql's ClusterError takes a word of psql…
brettheap Nov 17, 2026
aefb982
T229q: Keep no psql stream in Cluster.psql's frame when it raises
brettheap Nov 17, 2026
905d8e5
T257zzf: Fail where a failed psql's raising frame in pgcluster keeps …
brettheap Nov 17, 2026
5b2652c
T229r: State _SQLSTATE's limit in its comment, as T229p's message say…
brettheap Nov 17, 2026
7d9119d
T229s: Say PYTEST_DONT_REWRITE in pgcluster's docstring, so an assert…
brettheap Nov 17, 2026
f8e8aca
T257zy: Show the STORE text read's own exit through the helper, not a…
brettheap Nov 17, 2026
8ba9811
T257zz: Make the static check's exit rule structural, catch or name e…
brettheap Nov 17, 2026
da97a03
T205f: Say exactly which --tb choices conftest's hook keeps, and whic…
brettheap Nov 17, 2026
99e7df0
T257zzg: Show the timer case's other failure as its class, kind and c…
brettheap Nov 17, 2026
e8dca97
T258u: Wait at most 1 s for a held psql's exit in exit_now, so a psql…
brettheap Nov 17, 2026
d9bba46
T258v: Name no login in _no_clear_text's failure, only its place amon…
brettheap Nov 17, 2026
e5c00cf
T255zd: Make [listed-as-expected] prove its planted value is in a lon…
brettheap Nov 17, 2026
5a8c56f
T255ze: Label the last warming read's stderr as stderr in [m5]'s thre…
brettheap Nov 17, 2026
cee9790
T257zzh: Make [sent-a-snapshot] and [refused-with-no-value] prove the…
brettheap Nov 17, 2026
48cfcf7
T257zzi: Fail every report regression under an explicit long, fulltra…
brettheap Nov 17, 2026
ad29ebb
T257zzj: Run [timed-out-writer]'s planted writer with -I, as the modu…
brettheap Nov 17, 2026
99a5ce3
T257zzk: Leave two blank lines, not three, after [timed-out-writer]'s…
brettheap Nov 17, 2026
fc58ab3
T255zf: Drop measure git's run before it raises, so pytest 8.3.4's lo…
brettheap Nov 17, 2026
f9c12c1
T258w: Keep managed's writer and git runs out of *args and **kw frame…
brettheap Nov 17, 2026
c6909eb
T257zzl: Name pgcluster's _DATACL foot line in the static check's doc…
brettheap Nov 17, 2026
66bfc0f
T229t: Keep no run in _run_ok's and git's frames when they raise, sin…
brettheap Nov 17, 2026
795cdaf
T257zzza: Fail where a chained pgcluster failure, as the fixtures and…
brettheap Nov 17, 2026
5723297
T229u: Drop login add's output from make_logins' frame once its passw…
brettheap Nov 17, 2026
b3d7002
T229v: Count a server-log line as ERROR, FATAL or PANIC only where it…
brettheap Nov 17, 2026
5115718
T229w: Make _SQLSTATE's comment say what the pattern refuses without …
brettheap Nov 17, 2026
0cfdfe6
T257zzzb: Draw T257zze's words so no source or path a report prints c…
brettheap Nov 17, 2026
857a41d
T257zzzc: Call commit_of directly in T257zzb's [commit-id], and give …
brettheap Nov 17, 2026
7c65172
T257zzzd: Make terminal-reporter writes sinks, resolve imported names…
brettheap Nov 17, 2026
2f87195
T257zzze: Follow a helper's text through every binding of a name, cou…
brettheap Nov 17, 2026
210a0d3
T257zzzf: Read a message maker's arguments in a message, all but a wh…
brettheap Nov 17, 2026
d00c7a6
T257zzzg: Name the parsers whose errors quote their input among the s…
brettheap Nov 17, 2026
4df592c
T258x: Say in Managed.logins' docstring that _passwords' and passfile…
brettheap Nov 17, 2026
78710f3
T257zzzh: Route PF9-42's report regressions through the override chec…
brettheap Nov 17, 2026
c16cebf
T257zzzi: Check that T257zzza's report renders the chained error itse…
brettheap Nov 17, 2026
21b75ad
T257zzzj: Walk the raising frames of _run_ok, git and make_logins for…
brettheap Nov 17, 2026
4e436d7
T229x: Count a server log's ERROR, FATAL and PANIC lines under manage…
brettheap Nov 17, 2026
3faf945
T257zzzk: Check log_tail's severe-line count under no prefix, the def…
brettheap Nov 17, 2026
4c63736
T257zzzl: Walk make_logins' frame when login add succeeds and the psq…
brettheap Nov 17, 2026
7330ce8
T257zzzm: Make a terminal writer's write, a reporter's section and re…
brettheap Nov 17, 2026
1d16c0c
T257zzzn: Name the breadth of the _DATACL exemption and the exit rule…
brettheap Nov 17, 2026
f9e4409
Merge of PR 97
mergify[bot] Nov 21, 2026
5eda1ed
Merge of PR 103
mergify[bot] Nov 21, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -534,6 +534,15 @@ def pytest_configure(config):
raise pytest.UsageError(refusal)
if not config.pluginmanager.has_plugin(pgcluster.PLUGIN_NAME):
config.pluginmanager.register(pgcluster, pgcluster.PLUGIN_NAME)
# SHORT TRACEBACKS UNLESS ASKED (#165, lane 3's ruling 6949488277 on lane
# 2's pre-review RV9-38 of P09, B1): pytest's default `auto` prints a long
# entry's frame arguments, a helper's raw stream or a statement's password
# among them, in the terminal and in --junitxml. `short` prints none. An
# explicit `--tb` other than `auto` stays as given; `--tb=auto` cannot be
# told from the default, so it becomes short too. `--tb=long`,
# `--fulltrace` (which forces long) and `--showlocals` are not secret-safe.
if config.getoption("tbstyle", "auto") == "auto":
config.option.tbstyle = "short"


def pytest_report_header(config):
Expand Down
1 change: 1 addition & 0 deletions tests/fixtures/lanes-edit-v1.1.0/SHA256SUMS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
b68d0cbac35ac3bbac9e70790cafe63538821be582ca28cec0f7ec0f5c4745d2 lanes-edit.sh
18,977 changes: 18,977 additions & 0 deletions tests/fixtures/lanes-edit-v1.1.0/lanes-edit.sh

Large diffs are not rendered by default.

972 changes: 904 additions & 68 deletions tests/pgcluster.py

Large diffs are not rendered by default.

768 changes: 768 additions & 0 deletions tests/sql_register_cleanup.py

Large diffs are not rendered by default.

Empty file added tests/sql_register_landed/T210
Empty file.
Empty file added tests/sql_register_landed/T213
Empty file.
Empty file added tests/sql_register_landed/T214
Empty file.
Empty file added tests/sql_register_landed/T215
Empty file.
Empty file added tests/sql_register_landed/T219
Empty file.
Empty file added tests/sql_register_landed/T220
Empty file.
Empty file added tests/sql_register_landed/T224
Empty file.
Empty file added tests/sql_register_landed/T226
Empty file.
Empty file added tests/sql_register_landed/T229
Empty file.
Empty file added tests/sql_register_landed/T230
Empty file.
Empty file added tests/sql_register_landed/T237
Empty file.
Empty file added tests/sql_register_landed/T240
Empty file.
Empty file added tests/sql_register_landed/T241
Empty file.
Empty file added tests/sql_register_landed/T253
Empty file.
Empty file added tests/sql_register_landed/T254
Empty file.
Empty file added tests/sql_register_landed/T255
Empty file.
Empty file added tests/sql_register_landed/T257
Empty file.
Empty file added tests/sql_register_landed/T258
Empty file.
Empty file added tests/sql_register_landed/T270
Empty file.
Empty file added tests/sql_register_landed/T271
Empty file.
Empty file added tests/sql_register_landed/T273
Empty file.
Empty file added tests/sql_register_landed/T274
Empty file.
Empty file added tests/sql_register_landed/T276
Empty file.
Empty file added tests/sql_register_landed/T278
Empty file.
Empty file added tests/sql_register_landed/T279
Empty file.
6,560 changes: 6,560 additions & 0 deletions tests/test_sql_register_bounds.py

Large diffs are not rendered by default.

1,629 changes: 1,629 additions & 0 deletions tests/test_sql_register_disaster.py

Large diffs are not rendered by default.

1,619 changes: 1,619 additions & 0 deletions tests/test_sql_register_divergence.py

Large diffs are not rendered by default.

1,409 changes: 1,409 additions & 0 deletions tests/test_sql_register_drill.py

Large diffs are not rendered by default.

481 changes: 481 additions & 0 deletions tests/test_sql_register_fixture.py

Large diffs are not rendered by default.

8,179 changes: 8,179 additions & 0 deletions tests/test_sql_register_guard.py

Large diffs are not rendered by default.

1,841 changes: 1,841 additions & 0 deletions tests/test_sql_register_landing_expired.py

Large diffs are not rendered by default.

3,021 changes: 3,021 additions & 0 deletions tests/test_sql_register_managed.py

Large diffs are not rendered by default.

2,435 changes: 2,435 additions & 0 deletions tests/test_sql_register_measure.py

Large diffs are not rendered by default.

2,570 changes: 2,570 additions & 0 deletions tests/test_sql_register_outage.py

Large diffs are not rendered by default.

2,837 changes: 2,837 additions & 0 deletions tests/test_sql_register_render.py

Large diffs are not rendered by default.

3,854 changes: 3,854 additions & 0 deletions tests/test_sql_register_renderer_git.py

Large diffs are not rendered by default.

3,246 changes: 3,246 additions & 0 deletions tests/test_sql_register_rollback.py

Large diffs are not rendered by default.

80 changes: 80 additions & 0 deletions tests/test_sql_register_shape.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
# SPDX-License-Identifier: Apache-2.0
"""Feature 007's register shape (opensoft/openRepoTools#165): what each register
call looks like from outside, its argv, its credentials and its text.

THIS MODULE TODAY holds test 2's FP case, lane 2's T241 (AT-2, the test plan's
lines 646-781; FR-018, FR-059):
`test_an_unreachable_store_is_69_naming_the_store_and_never_the_files[<verb>]`.
Lane 1's T106 and T111 select their own cases here by `sql_register_shape`
and their words (B10 tasks:275 and :399); those cases are other tasks', which
add them to this module.

THE CASE runs each of S1's writes but `commit` as `lanes-edit.sh <verb>` on a
`mode=primary` workstation (`test_sql_register_writes.py`'s
`PrimaryWorkstation` and `WRITE_VERBS`), with T203's register fake first on
`PATH` answering every call that carries a request with `psql`'s exit 2 and
its "connection to server ... failed" text (AT-2, "Unreachable (FP)"). It
needs no engine, and fails until lane 4's L4-B3 (T415's attempt loop) lands,
by its own assertion: today's `lanes-edit.sh` writes the files whatever
`mode=` says.
"""

from __future__ import annotations

import re
import shutil

import pytest

from conftest import WINDOWS_SKIP
from test_sql_register_render import fake_calls, fake_psql_dir
from test_sql_register_writes import (PREPS, SECRET, WRITE_VERBS, PrimaryWorkstation,
unreachable_answers)

pytestmark = [WINDOWS_SKIP, pytest.mark.skipif(
shutil.which("bash") is None or shutil.which("git") is None,
reason="the lane tooling is bash over git")]

#: THE LANDING GATE'S TABLE (T280; `tests/sql_register_gate.py` reads it, and
#: T281 removes it in the last set): every id of this module waits for the
#: tasks T241's Order names, L4-B3's, L4-B4's and L4-B11's (tasks.md at
#: 204145ae). Lane 2's plan GP-24 wrote it (task sets 12b's rule 11).
SQL_REGISTER_GATE_TABLE = {
"*": ("T413", "T414", "T415", "T420"), # every id: the tasks all its rows share
}

#: What a writer that fell back to the files, or offered to, would say: the
#: register's file paths as a target, or the files mode by name. None may
#: appear in a refusal on primary (P213-215: "nothing ever written to the
#: files instead").
FILES_WORDS = re.compile(r"lanes/LANES\.md|lanes/log/|mode=files|files mode|files-mode"
r"|fall(ing)? ?back", re.I)


@pytest.mark.parametrize("verb", list(WRITE_VERBS))
def test_an_unreachable_store_is_69_naming_the_store_and_never_the_files(tmp_path, verb):
"""AT-2's FP oracle for the refusal's text (P213-214; contract section
2.6): `lanes-edit.sh <verb>` on primary, with the database unreachable,
exits 69; stderr names the store, `psql`'s own first line with the socket
it tried, and the error, with no password, no `PGPASSWORD` and no URL;
it never names the files as a target or a fallback; no call follows the
failed one; and the files under `lanes/` are as they were."""
ws = PrimaryWorkstation(tmp_path, prep=PREPS.get(verb))
fake = fake_psql_dir(ws.fakebin, answers=unreachable_answers(ws.dead))
ws.env.update(fake)
argv, lane = WRITE_VERBS[verb]
lanes_before = ws.git_state()[1]
proc = ws.run(argv, lane)
said = proc.stdout + proc.stderr
assert proc.returncode == 69, (
f"lanes-edit.sh {verb} on primary exited {proc.returncode}, not 69, with the store "
f"unreachable (L4-B3, T415's attempt loop): {proc.stderr[-800:]}")
assert str(ws.dead) in proc.stderr and "connection to server" in proc.stderr, (
f"stderr does not name the store and the error: {proc.stderr!r}")
assert SECRET not in said and "PGPASSWORD" not in said, "a credential reached the output"
assert not re.search(r"postgres(ql)?://", said), f"a URL reached the output: {said!r}"
assert not FILES_WORDS.search(proc.stderr), (
f"the refusal names the files: {FILES_WORDS.search(proc.stderr).group(0)!r} in "
f"{proc.stderr!r}")
assert len(fake_calls(fake)) == 1, f"calls after the failed one: {fake_calls(fake)}"
assert ws.git_state()[1] == lanes_before, "a file under lanes/ changed"
Loading
Loading