Some checks failed
Main Confidence / confidence (push) Failing after 45s
## Summary - introduce surface-aware compressed governance outcomes and reuse the shared truth/explanation seams for operator-first summaries - apply the compressed outcome hierarchy across baseline, evidence, review, review-pack, canonical review/evidence, and artifact-oriented operation-run surfaces - expand spec 214 fixtures and Pest coverage, and fix tenant-panel route assertions by generating explicit tenant-panel URLs in the affected Filament tests ## Validation - `cd apps/platform && ./vendor/bin/sail bin pint --dirty --format agent` - focused governance compression suite from `specs/214-governance-outcome-compression/quickstart.md` passed (`68` tests, `445` assertions) - `cd apps/platform && ./vendor/bin/sail artisan test --compact tests/Feature/Filament/InventoryItemResourceTest.php tests/Feature/Filament/BackupSetUiEnforcementTest.php tests/Feature/Filament/RestoreRunUiEnforcementTest.php` passed (`18` tests, `81` assertions) Co-authored-by: Ahmed Darrazi <ahmed.darrazi@live.de> Reviewed-on: #253
43 lines
1.6 KiB
Plaintext
43 lines
1.6 KiB
Plaintext
import * as Rx from 'rxjs';
|
|
import { CloseEvent, Command } from './command';
|
|
/**
|
|
* Defines which command(s) in a list must exit successfully (with an exit code of `0`):
|
|
*
|
|
* - `first`: only the first specified command;
|
|
* - `last`: only the last specified command;
|
|
* - `all`: all commands.
|
|
* - `command-{name|index}`: only the commands with the specified names or index.
|
|
* - `!command-{name|index}`: all commands but the ones with the specified names or index.
|
|
*/
|
|
export type SuccessCondition = 'first' | 'last' | 'all' | `command-${string | number}` | `!command-${string | number}`;
|
|
/**
|
|
* Provides logic to determine whether lists of commands ran successfully.
|
|
*/
|
|
export declare class CompletionListener {
|
|
private readonly successCondition;
|
|
private readonly scheduler?;
|
|
constructor({ successCondition, scheduler, }: {
|
|
/**
|
|
* How this instance will define that a list of commands ran successfully.
|
|
* Defaults to `all`.
|
|
*
|
|
* @see {SuccessCondition}
|
|
*/
|
|
successCondition?: SuccessCondition;
|
|
/**
|
|
* For testing only.
|
|
*/
|
|
scheduler?: Rx.SchedulerLike;
|
|
});
|
|
private isSuccess;
|
|
/**
|
|
* Given a list of commands, wait for all of them to exit and then evaluate their exit codes.
|
|
*
|
|
* @returns A Promise that resolves if the success condition is met, or rejects otherwise.
|
|
* In either case, the value is a list of close events for commands that spawned.
|
|
* Commands that didn't spawn are filtered out.
|
|
*/
|
|
listen(commands: Command[], abortSignal?: AbortSignal): Promise<CloseEvent[]>;
|
|
private emitWithScheduler;
|
|
}
|