@unotest/protocol 0.19.0 → 0.20.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,33 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.20.0] - 2026-08-24
4
+
5
+ ### Minor Changes
6
+
7
+ - 7957469: A status of its own for tests that are supposed to fail, and tiles that fade with age.
8
+
9
+ **`// @expect-fail`.** A scenario can declare that failing IS its assertion.
10
+ The marker lives in the comment block before the first code — with the
11
+ mandatory header (right after the colour line) or without one. The parser is
12
+ `parseScenarioAnnotations` in `@unotest/protocol`; `ScenarioMeta` gains an
13
+ `expectFail` field.
14
+
15
+ Such a scenario carries its own status in the viewer (`expected`, purple):
16
+ it stays out of the FAILED counter, out of the "failing now" badge and out
17
+ of the "Failing now" section. The inverse case — a marked test that
18
+ **passed** — turns red: whatever it was guarding stopped breaking and nobody
19
+ found out. One rule (`scenarioHealthStatus`) drives the dashboard, the
20
+ scenario tree and the badge, so the three cannot drift apart.
21
+
22
+ The runner does not interpret the marker: exit code and run status are
23
+ unchanged. The run really did fail — it is the test itself that is fine.
24
+
25
+ **Fading.** An overview tile dims as its last result ages: four steps (hour /
26
+ day / week / older) set the strength of the fill itself — 46 / 30 / 19 / 11%
27
+ of the status colour. The 11% floor keeps an old red still red. The time of
28
+ the last run is now part of the tile's accessible name — colour is the one
29
+ channel a screen reader does not have.
30
+
3
31
  ## [0.19.0] - 2026-08-23
4
32
 
5
33
  ### Minor Changes
package/dist/index.d.ts CHANGED
@@ -963,6 +963,23 @@ declare class RunnerNotConfiguredError extends Error {
963
963
  constructor(message: string);
964
964
  }
965
965
 
966
+ /** A test that is SUPPOSED to fail: the failure itself is the assertion.
967
+ * Its last run being red is the healthy state — and its last run being
968
+ * green is the broken one, because the thing it was guarding stopped
969
+ * being broken without anyone noticing. */
970
+ declare const EXPECT_FAIL_ANNOTATION = "expect-fail";
971
+ interface ScenarioAnnotations {
972
+ expectFail: boolean;
973
+ }
974
+ /** True for a line that is an annotation rather than prose or code. Used
975
+ * by the header parser to step over annotations while keeping the
976
+ * header's "no loose comments" rule for everything else. */
977
+ declare function isAnnotationLine(line: string): boolean;
978
+ /** Read the markers out of a scenario's source. Scans the leading run of
979
+ * comments and stops at the first line of code — an `// @expect-fail`
980
+ * further down the file is a comment about a step, not about the test. */
981
+ declare function parseScenarioAnnotations(source: string): ScenarioAnnotations;
982
+
966
983
  /** Parsed scenario metadata from the mandatory header lines
967
984
  * (per design-v0/decisions.md, "Test source format"):
968
985
  *
@@ -987,6 +1004,10 @@ interface ScenarioMeta {
987
1004
  name: string;
988
1005
  /** Project-relative path to the source file. */
989
1006
  path: string;
1007
+ /** The file carries `// @expect-fail` — a red run is this test's
1008
+ * healthy state, and a green one is the alarm. See
1009
+ * {@link ./scenario-annotations.ts}. */
1010
+ expectFail: boolean;
990
1011
  }
991
1012
 
992
1013
  /** Response of `GET /api/scenarios`. Folders are listed independently of
@@ -1532,4 +1553,4 @@ interface RuntimeStateFile {
1532
1553
  updatedAt: number;
1533
1554
  }
1534
1555
 
1535
- export { type AddVariablePlan, type AddVariablePlanInput, type AppPathPickerSpec, type AppServerEvent, type AuthoringRunRequest, BLOBS_DIR, type BreakpointEntry, type BreakpointsFile, COLLECTIONS_SUBDIR, COLLECTION_NAME_FORBIDDEN_RE, COMMANDS_FILE, type CheckSeverity, type CollectionMeta, type CollectionRunArtifact, type CollectionRunFinishedEvent, type CollectionRunRequest, type CollectionRunStartedEvent, type CollectionRunTab, type CollectionScenarioFinishedEvent, type CollectionScenarioStartedEvent, type CollectionTab, DAY_INDEX_FILE, type DbgCommand, type DbgCommandAbort, type DbgCommandClearBp, type DbgCommandContinue, type DbgCommandKind, type DbgCommandPause, type DbgCommandPickerStart, type DbgCommandPickerStop, type DbgCommandProbe, type DbgCommandRecord, type DbgCommandSetBp, type DbgCommandSnapshot, type DbgCommandStep, type DbgCommandWheel, type DebugCapabilities, type DoctorCheck, type DoctorContext, type DslDiagnostic, type DslValidateContext, type DslVocabArg, type DslVocabCategory, type DslVocabEntry, E2E_SUBDIR, ENV_FILE, type EnvFile, type EnvUpdate, type EnvVar, type ErrorMessage, type FailureBundleWrittenEvent, type FsBreakpointsChangedMessage, type FsCollectionRunStepMessage, type FsCollectionsChangedMessage, type FsHelpersChangedMessage, type FsRunFinishedMessage, type FsRunStartedMessage, type FsRunStepMessage, type FsScenariosChangedMessage, HEARTBEAT_FILE, HELPERS_SUBDIR, type HelperMeta, type HelperTab, type HostRequirement, type IDslLanguageService, type ILaunchedProcess, type IProcessLauncher, type IRunnerAdapter, InvalidBlobHashError, LOCK_FILE, LOG_FILE, type LaunchSpec, type LocatorPickedEvent, type LockFile, type LogLineMessage, type Matcher, PICKER_SNAPSHOT_FILE, type PausedEvent, type PickerMode, type ProbeMatch, type ProbePinned, type ProbeResult, type ProbeResultEvent, RUNNER_CONFIG_KEYS, RUNS_SUBDIR, RUNTIME_FILE, RUN_INDEX_SCHEMA_VERSION, RUN_MANIFEST_FILE, RUN_SOURCES_FILE, type RecordedActionKind, type RegexLiteral, type ResumedEvent, type RunArtifact, type RunFinishedEvent, type RunId, type RunIndexEntry, type RunIndexHeader, type RunKind, type RunManifest, type RunMeta, type RunOutcome, type RunRequest, type RunSources, type RunStartedEvent, type RunStatus, RunnerAdapterNotFoundError, RunnerNotConfiguredError, type RuntimeState, type RuntimeStateFile, SCENARIOS_INDEX_DIR, SCENARIOS_LATEST_FILE, SCENARIO_RECENT_WINDOW, SECRETS_FILE, SEGMENT_NAME_FORBIDDEN_RE, SNAPSHOTS_SUBDIR, STDERR_FILE, STDOUT_FILE, STEPS_FILE, type ScenarioLatestEntry, type ScenarioMeta, type ScenarioRunRequest, type ScenarioRunTab, type ScenarioTab, type ScenariosLatest, type ScenariosPayload, type ScreenshotEvent, type SnapshotTab, type StepFailEvent, type StepOkEvent, type StepStartedEvent, TERMINAL_RUNTIME_STATES, TERMINAL_WS_EVENT, type TabKind, type TabKindName, type TerminalClientMessage, type TerminalCloseMessage, type TerminalDataMessage, type TerminalErrorMessage, type TerminalExitMessage, type TerminalKind, type TerminalOutputMessage, type TerminalResizeMessage, type TerminalServerMessage, type TerminalSpawnMessage, type ToolCallEvent, type ToolResultEvent, UNOTEST_DIR, UnplaceableRunIdError, UnsupportedRunKindError, type VariableCategory, type VariableKind, type VariablePlanError, type WheelChangedEvent, type WsMessage, type WsMessageKind, activeEnvName, blobPathFor, blobRelPathFor, blobRelSegmentsFor, blobsRootFor, categorizeVariable, debugDirFor, debuggerFileFor, deleteShadowWarning, envFileFor, envKeys, envLayerFilesFor, foldScenarioRun, insertEnvVar, isExternalVarName, isFailingStatus, isRegexLiteral, isRunnerConfigKey, isTerminalRuntimeState, makeRunId, parseAppServerEvent, parseEnvContent, planAddVariable, projectRunDirFor, projectRunsRoot, regexLiteral, removeEnvVar, requireRunDirFor, runDirFor, runIdStartedAt, runsDirFor, sanitizeRunIdSegment, scenarioIndexFileName, scenarioRefFromFileName, secretsFileFor, secretsLayerFilesFor, serializeEnvValue, shardDaysDescending, shardDirFor, shardPathForRunId, shardPathForTimestamp, testDirFor, validateCollectionName, validateSegmentName };
1556
+ export { type AddVariablePlan, type AddVariablePlanInput, type AppPathPickerSpec, type AppServerEvent, type AuthoringRunRequest, BLOBS_DIR, type BreakpointEntry, type BreakpointsFile, COLLECTIONS_SUBDIR, COLLECTION_NAME_FORBIDDEN_RE, COMMANDS_FILE, type CheckSeverity, type CollectionMeta, type CollectionRunArtifact, type CollectionRunFinishedEvent, type CollectionRunRequest, type CollectionRunStartedEvent, type CollectionRunTab, type CollectionScenarioFinishedEvent, type CollectionScenarioStartedEvent, type CollectionTab, DAY_INDEX_FILE, type DbgCommand, type DbgCommandAbort, type DbgCommandClearBp, type DbgCommandContinue, type DbgCommandKind, type DbgCommandPause, type DbgCommandPickerStart, type DbgCommandPickerStop, type DbgCommandProbe, type DbgCommandRecord, type DbgCommandSetBp, type DbgCommandSnapshot, type DbgCommandStep, type DbgCommandWheel, type DebugCapabilities, type DoctorCheck, type DoctorContext, type DslDiagnostic, type DslValidateContext, type DslVocabArg, type DslVocabCategory, type DslVocabEntry, E2E_SUBDIR, ENV_FILE, EXPECT_FAIL_ANNOTATION, type EnvFile, type EnvUpdate, type EnvVar, type ErrorMessage, type FailureBundleWrittenEvent, type FsBreakpointsChangedMessage, type FsCollectionRunStepMessage, type FsCollectionsChangedMessage, type FsHelpersChangedMessage, type FsRunFinishedMessage, type FsRunStartedMessage, type FsRunStepMessage, type FsScenariosChangedMessage, HEARTBEAT_FILE, HELPERS_SUBDIR, type HelperMeta, type HelperTab, type HostRequirement, type IDslLanguageService, type ILaunchedProcess, type IProcessLauncher, type IRunnerAdapter, InvalidBlobHashError, LOCK_FILE, LOG_FILE, type LaunchSpec, type LocatorPickedEvent, type LockFile, type LogLineMessage, type Matcher, PICKER_SNAPSHOT_FILE, type PausedEvent, type PickerMode, type ProbeMatch, type ProbePinned, type ProbeResult, type ProbeResultEvent, RUNNER_CONFIG_KEYS, RUNS_SUBDIR, RUNTIME_FILE, RUN_INDEX_SCHEMA_VERSION, RUN_MANIFEST_FILE, RUN_SOURCES_FILE, type RecordedActionKind, type RegexLiteral, type ResumedEvent, type RunArtifact, type RunFinishedEvent, type RunId, type RunIndexEntry, type RunIndexHeader, type RunKind, type RunManifest, type RunMeta, type RunOutcome, type RunRequest, type RunSources, type RunStartedEvent, type RunStatus, RunnerAdapterNotFoundError, RunnerNotConfiguredError, type RuntimeState, type RuntimeStateFile, SCENARIOS_INDEX_DIR, SCENARIOS_LATEST_FILE, SCENARIO_RECENT_WINDOW, SECRETS_FILE, SEGMENT_NAME_FORBIDDEN_RE, SNAPSHOTS_SUBDIR, STDERR_FILE, STDOUT_FILE, STEPS_FILE, type ScenarioAnnotations, type ScenarioLatestEntry, type ScenarioMeta, type ScenarioRunRequest, type ScenarioRunTab, type ScenarioTab, type ScenariosLatest, type ScenariosPayload, type ScreenshotEvent, type SnapshotTab, type StepFailEvent, type StepOkEvent, type StepStartedEvent, TERMINAL_RUNTIME_STATES, TERMINAL_WS_EVENT, type TabKind, type TabKindName, type TerminalClientMessage, type TerminalCloseMessage, type TerminalDataMessage, type TerminalErrorMessage, type TerminalExitMessage, type TerminalKind, type TerminalOutputMessage, type TerminalResizeMessage, type TerminalServerMessage, type TerminalSpawnMessage, type ToolCallEvent, type ToolResultEvent, UNOTEST_DIR, UnplaceableRunIdError, UnsupportedRunKindError, type VariableCategory, type VariableKind, type VariablePlanError, type WheelChangedEvent, type WsMessage, type WsMessageKind, activeEnvName, blobPathFor, blobRelPathFor, blobRelSegmentsFor, blobsRootFor, categorizeVariable, debugDirFor, debuggerFileFor, deleteShadowWarning, envFileFor, envKeys, envLayerFilesFor, foldScenarioRun, insertEnvVar, isAnnotationLine, isExternalVarName, isFailingStatus, isRegexLiteral, isRunnerConfigKey, isTerminalRuntimeState, makeRunId, parseAppServerEvent, parseEnvContent, parseScenarioAnnotations, planAddVariable, projectRunDirFor, projectRunsRoot, regexLiteral, removeEnvVar, requireRunDirFor, runDirFor, runIdStartedAt, runsDirFor, sanitizeRunIdSegment, scenarioIndexFileName, scenarioRefFromFileName, secretsFileFor, secretsLayerFilesFor, serializeEnvValue, shardDaysDescending, shardDirFor, shardPathForRunId, shardPathForTimestamp, testDirFor, validateCollectionName, validateSegmentName };
package/dist/index.js CHANGED
@@ -1 +1 @@
1
- const _0x55dbd9=_0x56d7;(function(_0x474380,_0x28e0e0){const _0x561be6={_0x91014b:0xbc,_0x22ed73:0x9c,_0x46e3f8:0xba,_0x519ab2:0xda,_0x1dec2b:0xab},_0x2fe5e=_0x56d7,_0x8b1947=_0x474380();while(!![]){try{const _0x2206cd=parseInt(_0x2fe5e(0xc1))/0x1*(-parseInt(_0x2fe5e(_0x561be6._0x91014b))/0x2)+parseInt(_0x2fe5e(0xd1))/0x3*(-parseInt(_0x2fe5e(_0x561be6._0x22ed73))/0x4)+-parseInt(_0x2fe5e(_0x561be6._0x46e3f8))/0x5+-parseInt(_0x2fe5e(0xdb))/0x6+-parseInt(_0x2fe5e(0xb3))/0x7+parseInt(_0x2fe5e(_0x561be6._0x519ab2))/0x8+-parseInt(_0x2fe5e(_0x561be6._0x1dec2b))/0x9*(-parseInt(_0x2fe5e(0xf1))/0xa);if(_0x2206cd===_0x28e0e0)break;else _0x8b1947['push'](_0x8b1947['shift']());}catch(_0x28b1de){_0x8b1947['push'](_0x8b1947['shift']());}}}(_0x1172,0xad63e));var __defProp=Object[_0x55dbd9(0xdc)],__name=(_0x18b725,_0xf9d37b)=>__defProp(_0x18b725,_0x55dbd9(0xe5),{'value':_0xf9d37b,'configurable':!![]});function parseAppServerEvent(_0x5a02d5){const _0x428109={_0x4bd19e:0xe4,_0x597ccc:0x10d,_0x298a5f:0xee},_0xc31960=_0x55dbd9,_0xcdb79a=_0x5a02d5[_0xc31960(_0x428109._0x4bd19e)]();if(!_0xcdb79a['startsWith']('{'))return null;try{const _0x9c6880=JSON[_0xc31960(_0x428109._0x597ccc)](_0xcdb79a);if(_0x9c6880[_0xc31960(_0x428109._0x298a5f)]===_0xc31960(0xd4)||_0x9c6880[_0xc31960(0xee)]===_0xc31960(0xed)||_0x9c6880[_0xc31960(_0x428109._0x298a5f)]==='app-server:error')return _0x9c6880;return null;}catch{return null;}}__name(parseAppServerEvent,_0x55dbd9(0x121));var UNOTEST_DIR=_0x55dbd9(0xa9),E2E_SUBDIR=_0x55dbd9(0xfe),HELPERS_SUBDIR=_0x55dbd9(0xf7),COLLECTIONS_SUBDIR='_collections',RUNS_SUBDIR=_0x55dbd9(0xde),SNAPSHOTS_SUBDIR='.snapshots';function testDirFor(_0x53897b){return''+E2E_SUBDIR+_0x53897b;}__name(testDirFor,_0x55dbd9(0xb4));function runsDirFor(_0x2fefd8){return''+RUNS_SUBDIR+_0x2fefd8;}__name(runsDirFor,_0x55dbd9(0xd9));function debugDirFor(_0x37ad7a){const _0x189a2e={_0x23be89:0xb5},_0x44e82b=_0x55dbd9;return _0x44e82b(_0x189a2e._0x23be89)+_0x37ad7a;}__name(debugDirFor,_0x55dbd9(0x123));function debuggerFileFor(_0x19eeb8){const _0x2aba79={_0x3a4713:0xbe},_0x9b3a61=_0x55dbd9;return UNOTEST_DIR+_0x9b3a61(_0x2aba79._0x3a4713)+_0x19eeb8+_0x9b3a61(0xc0);}__name(debuggerFileFor,_0x55dbd9(0xcf));var LOCK_FILE=_0x55dbd9(0xc4),LOG_FILE='.viewer.log',STEPS_FILE=_0x55dbd9(0x9d),HEARTBEAT_FILE=_0x55dbd9(0x9a),DAY_INDEX_FILE=_0x55dbd9(0x117),SCENARIOS_INDEX_DIR=_0x55dbd9(0xb7),SCENARIOS_LATEST_FILE='_latest.json',STDOUT_FILE=_0x55dbd9(0xfa),STDERR_FILE='stderr.log',COMMANDS_FILE=_0x55dbd9(0xa6),RUNTIME_FILE=_0x55dbd9(0xd8),PICKER_SNAPSHOT_FILE=_0x55dbd9(0x11d),ENV_FILE=_0x55dbd9(0xcd),SECRETS_FILE=_0x55dbd9(0x101);function envFileFor(_0x16c70e,_0x518a4f){return''+ENV_FILE+_0x16c70e+(_0x518a4f?'.'+_0x518a4f:'');}__name(envFileFor,_0x55dbd9(0xf0));function secretsFileFor(_0x396655,_0x457bc9){return''+SECRETS_FILE+_0x396655+(_0x457bc9?'.'+_0x457bc9:'');}__name(secretsFileFor,_0x55dbd9(0x116));function envLayerFilesFor(_0xc196f7,_0x38954b){return layersFor(ENV_FILE,_0xc196f7,_0x38954b);}__name(envLayerFilesFor,'envLayerFilesFor');function secretsLayerFilesFor(_0x425561,_0x341176){return layersFor(SECRETS_FILE,_0x425561,_0x341176);}__name(secretsLayerFilesFor,_0x55dbd9(0xc9));function layersFor(_0x404762,_0x1cb01f,_0x2031d4){const _0x83d815={_0x380996:0x11e},_0x2ad1aa=_0x55dbd9,_0x3b0b75=[_0x404762];if(_0x1cb01f)_0x3b0b75['push'](''+_0x404762+_0x1cb01f);if(_0x2031d4){_0x3b0b75[_0x2ad1aa(_0x83d815._0x380996)](_0x404762+'.'+_0x2031d4);if(_0x1cb01f)_0x3b0b75[_0x2ad1aa(0x11e)](''+_0x404762+_0x1cb01f+'.'+_0x2031d4);}return _0x3b0b75;}__name(layersFor,_0x55dbd9(0xac));function activeEnvName(_0x2ac644){const _0x15d5c1=_0x55dbd9,_0x530e3=_0x2ac644['UNOTEST_ENV']?.[_0x15d5c1(0xe4)]();return _0x530e3?_0x530e3:void 0x0;}__name(activeEnvName,_0x55dbd9(0xae));function isRegexLiteral(_0x1c80a9){const _0x35877f={_0x52ac06:0xd2,_0x10252d:0xee,_0x485b54:0x96,_0x122b40:0x95,_0xd433f:0x127},_0x2ff2e4=_0x55dbd9;return typeof _0x1c80a9===_0x2ff2e4(_0x35877f._0x52ac06)&&_0x1c80a9!==null&&_0x1c80a9[_0x2ff2e4(_0x35877f._0x10252d)]==='regex'&&typeof _0x1c80a9[_0x2ff2e4(_0x35877f._0x485b54)]===_0x2ff2e4(_0x35877f._0x122b40)&&typeof _0x1c80a9[_0x2ff2e4(_0x35877f._0xd433f)]===_0x2ff2e4(0x95);}__name(isRegexLiteral,_0x55dbd9(0x92));function regexLiteral(_0x3eddb5,_0x2ae071=''){const _0x51f84d={_0x59a29e:0x8d},_0x5b8118=_0x55dbd9;return{'kind':_0x5b8118(_0x51f84d._0x59a29e),'source':_0x3eddb5,'flags':_0x2ae071};}__name(regexLiteral,'regexLiteral');var RAND_BYTES=0x6;function makeRunId(_0x3e5ac4){const _0x1f75d1=_0x55dbd9,_0x301109=sanitizeRunIdSegment(_0x3e5ac4),_0x1e7563=Date[_0x1f75d1(0xb6)]()[_0x1f75d1(0xff)](0x24),_0x1edb8a=new Uint8Array(RAND_BYTES);globalThis[_0x1f75d1(0xaa)]['getRandomValues'](_0x1edb8a);let _0x4c93f1='';for(let _0x23f78=0x0;_0x23f78<_0x1edb8a[_0x1f75d1(0x9b)];_0x23f78++){_0x4c93f1+=_0x1edb8a[_0x23f78][_0x1f75d1(0xff)](0x10)[_0x1f75d1(0x11c)](0x2,'0');}return _0x301109+'-'+_0x1e7563+'-'+_0x4c93f1;}function _0x56d7(_0x3f339c,_0x5e47f5){_0x3f339c=_0x3f339c-0x8c;const _0x11721e=_0x1172();let _0x56d7f3=_0x11721e[_0x3f339c];if(_0x56d7['bZwYBc']===undefined){var _0x4b4f4b=function(_0x6c7179){const _0x45d0ca='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x18b725='',_0xf9d37b='';for(let _0x5a02d5=0x0,_0xcdb79a,_0x9c6880,_0x53897b=0x0;_0x9c6880=_0x6c7179['charAt'](_0x53897b++);~_0x9c6880&&(_0xcdb79a=_0x5a02d5%0x4?_0xcdb79a*0x40+_0x9c6880:_0x9c6880,_0x5a02d5++%0x4)?_0x18b725+=String['fromCharCode'](0xff&_0xcdb79a>>(-0x2*_0x5a02d5&0x6)):0x0){_0x9c6880=_0x45d0ca['indexOf'](_0x9c6880);}for(let _0x2fefd8=0x0,_0x37ad7a=_0x18b725['length'];_0x2fefd8<_0x37ad7a;_0x2fefd8++){_0xf9d37b+='%'+('00'+_0x18b725['charCodeAt'](_0x2fefd8)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0xf9d37b);};_0x56d7['lNFvly']=_0x4b4f4b,_0x56d7['rdoynN']={},_0x56d7['bZwYBc']=!![];}const _0x31a493=_0x11721e[0x0],_0x2a0560=_0x3f339c+_0x31a493,_0x5153ef=_0x56d7['rdoynN'][_0x2a0560];return!_0x5153ef?(_0x56d7f3=_0x56d7['lNFvly'](_0x56d7f3),_0x56d7['rdoynN'][_0x2a0560]=_0x56d7f3):_0x56d7f3=_0x5153ef,_0x56d7f3;}__name(makeRunId,_0x55dbd9(0xce));function sanitizeRunIdSegment(_0x16d215){const _0x9c437d={_0x5ee68e:0x100},_0x500e2a=_0x55dbd9,_0x4cb1d6=_0x16d215[_0x500e2a(0x100)](/[^a-zA-Z0-9_-]+/g,'-')[_0x500e2a(0x100)](/-+/g,'-')[_0x500e2a(_0x9c437d._0x5ee68e)](/^-|-$/g,'');return _0x4cb1d6[_0x500e2a(0x9b)]>0x0?_0x4cb1d6:_0x500e2a(0xef);}__name(sanitizeRunIdSegment,_0x55dbd9(0xc6));var RANDOM_SUFFIX_RE=/^[0-9a-f]{6,}$/,MIN_PLAUSIBLE_MS=Date[_0x55dbd9(0xc8)](0x7e4,0x0,0x1),MAX_PLAUSIBLE_MS=Date[_0x55dbd9(0xc8)](0x834,0x0,0x1);function runIdStartedAt(_0x10b1b5){const _0x1717d1={_0x2e834a:0x9b,_0x1eb978:0x91},_0x51db59=_0x55dbd9,_0x3cfab1=_0x10b1b5[_0x51db59(0xd6)]('-');if(_0x3cfab1[_0x51db59(0x9b)]<0x3)return null;const _0xf70617=_0x3cfab1[_0x3cfab1[_0x51db59(_0x1717d1._0x2e834a)]-0x1];if(!RANDOM_SUFFIX_RE[_0x51db59(0x91)](_0xf70617))return null;const _0x34a3e0=_0x3cfab1[_0x3cfab1[_0x51db59(0x9b)]-0x2];if(!/^[0-9a-z]+$/[_0x51db59(_0x1717d1._0x1eb978)](_0x34a3e0))return null;const _0x180414=parseInt(_0x34a3e0,0x24);if(!Number['isFinite'](_0x180414))return null;if(_0x180414<MIN_PLAUSIBLE_MS||_0x180414>=MAX_PLAUSIBLE_MS)return null;return _0x180414;}__name(runIdStartedAt,_0x55dbd9(0xe8));function shardPathForTimestamp(_0x4893b4){const _0x170557={_0x4a14b6:0x11c},_0x2463fb=_0x55dbd9,_0x47f6a5=new Date(_0x4893b4),_0x4acd1b=String(_0x47f6a5['getUTCFullYear']())[_0x2463fb(_0x170557._0x4a14b6)](0x4,'0'),_0x4a8085=String(_0x47f6a5[_0x2463fb(0x115)]()+0x1)['padStart'](0x2,'0'),_0x3ac2b6=String(_0x47f6a5[_0x2463fb(0x110)]())[_0x2463fb(0x11c)](0x2,'0');return _0x4acd1b+'/'+_0x4a8085+'/'+_0x3ac2b6;}__name(shardPathForTimestamp,_0x55dbd9(0x10a));function shardPathForRunId(_0x41970a){const _0x5a932e=runIdStartedAt(_0x41970a);return _0x5a932e===null?null:shardPathForTimestamp(_0x5a932e);}__name(shardPathForRunId,_0x55dbd9(0xec));function runDirFor(_0x2f6587,_0x4b882b){const _0x264ce1=shardPathForRunId(_0x4b882b);return _0x264ce1===null?null:_0x2f6587+'/'+_0x264ce1+'/'+_0x4b882b;}__name(runDirFor,_0x55dbd9(0xe9));var UnplaceableRunIdError=class extends Error{static{__name(this,'UnplaceableRunIdError');}constructor(_0x2e071d){const _0x50d998={_0x20ad3c:0xe5,_0x439e2f:0x10c},_0x523b6f=_0x55dbd9;super('runId\x20carries\x20no\x20timestamp,\x20cannot\x20place\x20it\x20in\x20a\x20shard:\x20'+_0x2e071d),this[_0x523b6f(_0x50d998._0x20ad3c)]=_0x523b6f(_0x50d998._0x439e2f);}};function requireRunDirFor(_0x34e9a9,_0x43f555){const _0x4f4afb=runDirFor(_0x34e9a9,_0x43f555);if(_0x4f4afb===null)throw new UnplaceableRunIdError(_0x43f555);return _0x4f4afb;}__name(requireRunDirFor,_0x55dbd9(0x128));function projectRunsRoot(_0x10ad64=''){return UNOTEST_DIR+'/'+runsDirFor(_0x10ad64);}__name(projectRunsRoot,_0x55dbd9(0x102));function projectRunDirFor(_0x3224c4,_0x1dc1b4=''){return requireRunDirFor(projectRunsRoot(_0x1dc1b4),_0x3224c4);}__name(projectRunDirFor,_0x55dbd9(0xad));function shardDirFor(_0x79da13,_0x5860f9){return _0x79da13+'/'+shardPathForTimestamp(_0x5860f9);}__name(shardDirFor,_0x55dbd9(0xe2));function*shardDaysDescending(_0x72f4c5,_0x12084a,_0x3ce67a){const _0x31e307={_0x15ff35:0xa1},_0x5b2cd1=_0x55dbd9,_0x561bf0=0x5265c00;let _0x2fb737=Math[_0x5b2cd1(_0x31e307._0x15ff35)](_0x12084a/_0x561bf0)*_0x561bf0;for(let _0x48f683=0x0;_0x48f683<_0x3ce67a;_0x48f683++){yield shardDirFor(_0x72f4c5,_0x2fb737),_0x2fb737-=_0x561bf0;}}__name(shardDaysDescending,_0x55dbd9(0xeb));var RUN_INDEX_SCHEMA_VERSION=0x2,SCENARIO_RECENT_WINDOW=0xc;function isFailingStatus(_0x3353e2){return _0x3353e2==='failed'||_0x3353e2==='interrupted';}__name(isFailingStatus,'isFailingStatus');function foldScenarioRun(_0x33ff12,_0x2eb00f){const _0x5b7917={_0xc83263:0x11a,_0x318ec0:0xca,_0x254eac:0xb2},_0x3a4876=_0x55dbd9,_0x1fa5c3={'lastRunId':_0x2eb00f['runId'],'lastStatus':_0x2eb00f[_0x3a4876(0x118)],'lastAt':_0x2eb00f[_0x3a4876(0xb2)],'lastDurationMs':_0x2eb00f[_0x3a4876(0xf5)],'recent':[..._0x33ff12?.[_0x3a4876(_0x5b7917._0xc83263)]??[],_0x2eb00f[_0x3a4876(0x118)]][_0x3a4876(_0x5b7917._0x318ec0)](-SCENARIO_RECENT_WINDOW)};if(!isFailingStatus(_0x2eb00f['status']))return{..._0x1fa5c3,'failStreak':0x0,'failingSince':null};const _0x310545=(_0x33ff12?.['failStreak']??0x0)+0x1;return{..._0x1fa5c3,'failStreak':_0x310545,'failingSince':_0x310545===0x1?_0x2eb00f[_0x3a4876(_0x5b7917._0x254eac)]:_0x33ff12?.[_0x3a4876(0xea)]??_0x2eb00f[_0x3a4876(_0x5b7917._0x254eac)]};}__name(foldScenarioRun,_0x55dbd9(0x9e));function scenarioIndexFileName(_0x59aefd){const _0x4d483a=_0x55dbd9;return encodeURIComponent(_0x59aefd)+_0x4d483a(0x114);}__name(scenarioIndexFileName,'scenarioIndexFileName');function scenarioRefFromFileName(_0x431542){const _0x12364a={_0x42e9b2:0x114},_0x292349=_0x55dbd9;if(!_0x431542[_0x292349(0xa8)]('.jsonl'))return null;try{return decodeURIComponent(_0x431542['slice'](0x0,-_0x292349(_0x12364a._0x42e9b2)['length']));}catch{return null;}}__name(scenarioRefFromFileName,_0x55dbd9(0x98));var BLOBS_DIR=_0x55dbd9(0xb9),GENERATION_SEP='~',HASH_RE=/^[0-9a-f]{8,}$/,InvalidBlobHashError=class extends Error{static{__name(this,_0x55dbd9(0x10b));}constructor(_0x213362){const _0x47e6c4={_0xfde91f:0xe5},_0x52eab2=_0x55dbd9;super(_0x52eab2(0xfd)+_0x213362),this[_0x52eab2(_0x47e6c4._0xfde91f)]='InvalidBlobHashError';}};function blobPathFor(_0x1503c0,_0x3c4df1,_0x3d5ae4,_0xee2a32=0x0){return _0x1503c0+'/'+blobRelPathFor(_0x3c4df1,_0x3d5ae4,_0xee2a32);}__name(blobPathFor,_0x55dbd9(0xbd));function blobRelSegmentsFor(_0x2f6364,_0x4bc9ac,_0x37685e=0x0){const _0x47536a={_0x274b82:0xca},_0xa10f51=_0x55dbd9;if(!HASH_RE[_0xa10f51(0x91)](_0x2f6364))throw new InvalidBlobHashError(_0x2f6364);const _0x553568=_0x37685e>0x0?''+GENERATION_SEP+_0x37685e:'';return[BLOBS_DIR,_0x2f6364[_0xa10f51(0xca)](0x0,0x2),_0x2f6364[_0xa10f51(_0x47536a._0x274b82)](0x2,0x4),''+_0x2f6364+_0x553568+'.'+_0x4bc9ac];}__name(blobRelSegmentsFor,_0x55dbd9(0x129));function blobRelPathFor(_0x4a4670,_0x5f41d8,_0x7eb0f8=0x0){return blobRelSegmentsFor(_0x4a4670,_0x5f41d8,_0x7eb0f8)['join']('/');}__name(blobRelPathFor,'blobRelPathFor');function blobsRootFor(_0x458c2a){return _0x458c2a+'/'+BLOBS_DIR;}__name(blobsRootFor,_0x55dbd9(0x112));var FS_UNSAFE_NAME_RE=/[\\/:*?"<>|\x00-\x1f]/;function validateFsSafeName(_0x3d3171,_0x3be28a){const _0x18e1c5={_0x3fdf0a:0x94,_0x37e545:0xe4,_0xca4452:0x9b,_0x5e98d2:0x90},_0x4b1130=_0x55dbd9;if(typeof _0x3d3171!==_0x4b1130(0x95))return _0x4b1130(_0x18e1c5._0x3fdf0a);const _0x3cc7fb=_0x3d3171[_0x4b1130(_0x18e1c5._0x37e545)]();if(_0x3cc7fb[_0x4b1130(_0x18e1c5._0xca4452)]===0x0)return _0x4b1130(0xe3);if(_0x3cc7fb==='.'||_0x3cc7fb==='..')return'must\x20not\x20be\x20\x22.\x22\x20or\x20\x22..\x22';if(_0x3cc7fb[_0x4b1130(_0x18e1c5._0x5e98d2)]('.'))return'must\x20not\x20start\x20with\x20\x27.\x27';if(_0x3be28a?.['reservedUnderscore']&&_0x3cc7fb[_0x4b1130(0x90)]('_'))return'must\x20not\x20start\x20with\x20\x27_\x27\x20(reserved)';if(FS_UNSAFE_NAME_RE['test'](_0x3cc7fb))return'must\x20not\x20contain\x20\x5c\x20/\x20:\x20*\x20?\x20\x22\x20<\x20>\x20|\x20or\x20control\x20characters';return null;}__name(validateFsSafeName,_0x55dbd9(0x106));var COLLECTION_NAME_FORBIDDEN_RE=FS_UNSAFE_NAME_RE;function validateCollectionName(_0x376832){return validateFsSafeName(_0x376832);}__name(validateCollectionName,_0x55dbd9(0xd0));var RUN_MANIFEST_FILE=_0x55dbd9(0xa3),RUN_SOURCES_FILE=_0x55dbd9(0xa2),UnsupportedRunKindError=class extends Error{static{__name(this,_0x55dbd9(0xf4));}constructor(_0xc9554f,_0x3f9102){super('runner\x20\x22'+_0x3f9102+'\x22\x20does\x20not\x20support\x20run\x20kind\x20\x22'+_0xc9554f+'\x22'),this['name']='UnsupportedRunKindError';}},RunnerAdapterNotFoundError=class extends Error{static{__name(this,_0x55dbd9(0xd7));}constructor(_0x2816aa,_0x5be907){const _0x52c42e=_0x55dbd9;super('cannot\x20load\x20runner\x20adapter\x20\x22'+_0x2816aa+_0x52c42e(0xa4)+_0x5be907),this[_0x52c42e(0xe5)]=_0x52c42e(0xd7);}},RunnerNotConfiguredError=class extends Error{static{__name(this,_0x55dbd9(0x108));}constructor(_0xfee877){const _0x34abb2=_0x55dbd9;super(_0xfee877),this[_0x34abb2(0xe5)]='RunnerNotConfiguredError';}},SEGMENT_NAME_FORBIDDEN_RE=FS_UNSAFE_NAME_RE;function validateSegmentName(_0x30ae07){return validateFsSafeName(_0x30ae07,{'reservedUnderscore':!![]});}__name(validateSegmentName,_0x55dbd9(0xf2));var TERMINAL_WS_EVENT=_0x55dbd9(0x119),RUNNER_CONFIG_KEYS=new Set([_0x55dbd9(0xe6),_0x55dbd9(0xb8),_0x55dbd9(0xdd),_0x55dbd9(0xa7),'UNOTEST_DEFAULT_NAVIGATION_TIMEOUT_MS',_0x55dbd9(0xe1),'UNOTEST_LOCALE',_0x55dbd9(0x10f),_0x55dbd9(0x124),_0x55dbd9(0xa0),_0x55dbd9(0x105),_0x55dbd9(0x8f),'UNOTEST_DEBUG_PREVIEW_BYTES','UNOTEST_DEBUG_HTML_MAX_BYTES',_0x55dbd9(0xd5),_0x55dbd9(0xcb),_0x55dbd9(0xf9),_0x55dbd9(0x9f),_0x55dbd9(0x113),'FORCE_COLOR','DATABASE_URL']);function isRunnerConfigKey(_0x6204a0){const _0xc0c24c=_0x55dbd9;return RUNNER_CONFIG_KEYS[_0xc0c24c(0xd3)](_0x6204a0);}__name(isRunnerConfigKey,'isRunnerConfigKey');function categorizeVariable(_0x5a9adc){const _0x6eebe9={_0x206e1f:0x96,_0x128abd:0x10e,_0x3c70d1:0xe5},_0x51efe5=_0x55dbd9;if(_0x5a9adc[_0x51efe5(_0x6eebe9._0x206e1f)]==='secrets')return _0x51efe5(_0x6eebe9._0x128abd);return isRunnerConfigKey(_0x5a9adc[_0x51efe5(_0x6eebe9._0x3c70d1)])?_0x51efe5(0x93):'app';}__name(categorizeVariable,_0x55dbd9(0x126));function isExternalVarName(_0x1094af){const _0x4ad769=_0x55dbd9;return/^[A-Z][A-Z0-9_]*$/[_0x4ad769(0x91)](_0x1094af);}__name(isExternalVarName,_0x55dbd9(0xc3));var ENV_KEY_RE=/^[A-Za-z_][A-Za-z0-9_]*$/;function*assignmentEntries(_0x3c5279){const _0x54ebf3={_0x2b46e0:0x103,_0x2db8e9:0xca,_0x59b402:0xe4},_0x413b00=_0x55dbd9;for(const _0x55ec85 of _0x3c5279[_0x413b00(0xd6)](/\r?\n/)){const _0x23b22a=_0x55ec85[_0x413b00(0xe4)]();if(_0x23b22a===''||_0x23b22a[_0x413b00(0x90)]('#'))continue;const _0x456341=_0x23b22a[_0x413b00(_0x54ebf3._0x2b46e0)]('=');if(_0x456341<=0x0)continue;const _0x173a01=_0x23b22a[_0x413b00(_0x54ebf3._0x2db8e9)](0x0,_0x456341)['trim']();if(!ENV_KEY_RE['test'](_0x173a01))continue;yield[_0x173a01,_0x23b22a[_0x413b00(_0x54ebf3._0x2db8e9)](_0x456341+0x1)[_0x413b00(_0x54ebf3._0x59b402)]()];}}__name(assignmentEntries,_0x55dbd9(0xfb));function parseEnvContent(_0x24c862){const _0x2c4b35={_0x5a2542:0x9b,_0x16b2c8:0xca},_0x52c8f1=_0x55dbd9,_0x13586a={};for(const [_0x3303e2,_0x308fe5]of assignmentEntries(_0x24c862)){let _0x225f74=_0x308fe5;if(_0x225f74[_0x52c8f1(_0x2c4b35._0x5a2542)]>=0x2){const _0x2f907a=_0x225f74[0x0],_0x5b7a0b=_0x225f74[_0x225f74['length']-0x1];(_0x2f907a==='\x22'||_0x2f907a==='\x27')&&_0x2f907a===_0x5b7a0b&&(_0x225f74=_0x225f74[_0x52c8f1(_0x2c4b35._0x16b2c8)](0x1,-0x1));}_0x13586a[_0x3303e2]=_0x225f74;}return _0x13586a;}__name(parseEnvContent,_0x55dbd9(0x111));function serializeEnvValue(_0x3b8f3e){const _0x4d0b71={_0x371817:0x91,_0x637b23:0x100},_0x5d8247=_0x55dbd9;if(_0x3b8f3e==='')return'';if(/[\s#"'=\\]|^[`]/[_0x5d8247(_0x4d0b71._0x371817)](_0x3b8f3e)||/[\n\r]/['test'](_0x3b8f3e)){const _0x17a0ac=_0x3b8f3e[_0x5d8247(0x100)](/\\/g,'\x5c\x5c')[_0x5d8247(0x100)](/"/g,'\x5c\x22')[_0x5d8247(_0x4d0b71._0x637b23)](/\n/g,'\x5cn')[_0x5d8247(0x100)](/\r/g,'\x5cr');return'\x22'+_0x17a0ac+'\x22';}return _0x3b8f3e;}__name(serializeEnvValue,'serializeEnvValue');function envKeys(_0x5ac57c){const _0x1ac3fa={_0x98c127:0xf3},_0x2cbcbe=_0x55dbd9,_0x4a15d6=new Set();for(const [_0x594175]of assignmentEntries(_0x5ac57c))_0x4a15d6[_0x2cbcbe(_0x1ac3fa._0x98c127)](_0x594175);return _0x4a15d6;}__name(envKeys,'envKeys');function isSectionDivider(_0x30db12){const _0x23cd01={_0x430abf:0xe4},_0x6676ee=_0x55dbd9,_0x2fe0fe=_0x30db12[_0x6676ee(_0x23cd01._0x430abf)]();return _0x2fe0fe['startsWith']('#')&&/---/[_0x6676ee(0x91)](_0x2fe0fe);}__name(isSectionDivider,_0x55dbd9(0xf8));function isAssignmentLine(_0x1dd9e1){const _0xf1369e={_0x31db1a:0x90,_0xf031fd:0x91},_0x2bc3ec=_0x55dbd9,_0x3034b5=_0x1dd9e1['trim']();if(_0x3034b5===''||_0x3034b5[_0x2bc3ec(_0xf1369e._0x31db1a)]('#'))return![];const _0x4490cb=_0x3034b5[_0x2bc3ec(0x103)]('=');return _0x4490cb>0x0&&ENV_KEY_RE[_0x2bc3ec(_0xf1369e._0xf031fd)](_0x3034b5[_0x2bc3ec(0xca)](0x0,_0x4490cb)['trim']());}__name(isAssignmentLine,_0x55dbd9(0xc7));function isAssignmentOf(_0x47f13c,_0x57695f){const _0x3bb042={_0x2b58df:0x103,_0x237bb3:0xe4},_0x3e1b25=_0x55dbd9,_0x140a2c=_0x47f13c[_0x3e1b25(0xe4)]();if(_0x140a2c===''||_0x140a2c['startsWith']('#'))return![];const _0x4d219f=_0x140a2c[_0x3e1b25(_0x3bb042._0x2b58df)]('=');if(_0x4d219f<=0x0)return![];return _0x140a2c[_0x3e1b25(0xca)](0x0,_0x4d219f)[_0x3e1b25(_0x3bb042._0x237bb3)]()===_0x57695f;}__name(isAssignmentOf,'isAssignmentOf');function splitLines(_0x33b3f2){const _0x2d343d={_0x231ab7:0xd6},_0xb9be53=_0x55dbd9,_0xdcef18=_0x33b3f2['endsWith']('\x0a'),_0x50523f=_0xdcef18?_0x33b3f2['slice'](0x0,-0x1):_0x33b3f2;return{'lines':_0x50523f===''?[]:_0x50523f[_0xb9be53(_0x2d343d._0x231ab7)]('\x0a'),'trailingNewline':_0xdcef18};}__name(splitLines,_0x55dbd9(0x125));function joinLines(_0x1a752f,_0x1ed786){const _0xac8e05={_0x559c77:0xfc},_0x20cfc3=_0x55dbd9,_0x3ae247=_0x1a752f[_0x20cfc3(_0xac8e05._0x559c77)]('\x0a');return _0x1ed786||_0x3ae247===''?_0x3ae247+'\x0a':_0x3ae247;}__name(joinLines,'joinLines');function insertEnvVar(_0x664ff8,_0x38ff09,_0x379ccf,_0x4510eb){const _0x2e6247={_0x51ec9a:0x9b,_0x28a038:0xe4,_0x1037f7:0xcc,_0x382c06:0x11e},_0x4cb59d=_0x55dbd9,_0x48fb66=_0x38ff09+'='+serializeEnvValue(_0x379ccf),{lines:_0xee65f0,trailingNewline:_0x36c5bc}=splitLines(_0x664ff8);if(_0x4510eb){const _0x323e82=new RegExp('\x5cb'+_0x4510eb[_0x4cb59d(0x8e)]()+'\x5cb'),_0x21f405=_0xee65f0[_0x4cb59d(0x97)](_0x37b8a4=>isSectionDivider(_0x37b8a4)&&_0x323e82['test'](_0x37b8a4[_0x4cb59d(0x8e)]()));if(_0x21f405!==-0x1){let _0x148c22=_0xee65f0[_0x4cb59d(_0x2e6247._0x51ec9a)];for(let _0x5219ec=_0x21f405+0x1;_0x5219ec<_0xee65f0[_0x4cb59d(0x9b)];_0x5219ec++){if(isSectionDivider(_0xee65f0[_0x5219ec])){_0x148c22=_0x5219ec;break;}}let _0x1e4514=-0x1,_0x25b5ca=-0x1;for(let _0x3fba46=_0x21f405+0x1;_0x3fba46<_0x148c22;_0x3fba46++){if(_0xee65f0[_0x3fba46][_0x4cb59d(_0x2e6247._0x28a038)]()!=='')_0x25b5ca=_0x3fba46;if(isAssignmentLine(_0xee65f0[_0x3fba46]))_0x1e4514=_0x3fba46;}const _0x3a6370=_0x1e4514>=0x0?_0x1e4514:_0x25b5ca,_0x1a5dd4=_0x3a6370>=0x0?_0x3a6370+0x1:_0x21f405+0x1;return _0xee65f0[_0x4cb59d(_0x2e6247._0x1037f7)](_0x1a5dd4,0x0,_0x48fb66),joinLines(_0xee65f0,_0x36c5bc||_0xee65f0[_0x4cb59d(0x9b)]>0x0);}if(_0xee65f0[_0x4cb59d(0x9b)]>0x0)_0xee65f0['push']('');return _0xee65f0[_0x4cb59d(0x11e)]('#\x20---\x20'+_0x4510eb+_0x4cb59d(0xe0),_0x48fb66),joinLines(_0xee65f0,!![]);}return _0xee65f0[_0x4cb59d(_0x2e6247._0x382c06)](_0x48fb66),joinLines(_0xee65f0,!![]);}__name(insertEnvVar,_0x55dbd9(0xa5));function _0x1172(){const _0x360585=['igLZig5VDcbHigTUB3DUihj1BM5LCIbZzxr0Aw5NiokaLcbJAg9VC2uGB25LigzYB20GDgHLihj1BM5LCI1JB25MAwCGBgLZDc4','C2fUAxrPEMvsDw5jzfnLz21LBNq','AxnbC3nPz25Tzw50tgLUzq','vvrd','C2vJCMv0C0XHEwvYrMLSzxngB3i','C2XPy2u','vu5pvevtvf9orvrxt1jl','C3bSAwnL','Dw5VDgvZDc8Uzw52','BwfRzvj1BKLK','zgvIDwDNzxjgAwXLrM9Y','DMfSAwrHDgvdB2XSzwn0Aw9UtMfTzq','ouvnwfrsta','B2jQzwn0','AgfZ','yxbWlxnLCNzLCJPYzwfKEq','vu5pvevtvf9erujvr19lruvqx0nbteXt','C3bSAxq','uNvUBMvYqwrHChrLCK5VDezVDw5KrxjYB3i','CNvUDgLTzs5QC29U','CNvUC0rPCKzVCG','nty5mtaWme1Lt1jIzW','nZeZmtuWne9ss1ngqW','zgvMAw5LuhjVCgvYDhK','vu5pvevtvf9tte9xx01p','lNj1BNm','Dw5RBM93BI1YDw5UzxiTA2v5','ic0Tlq','vu5pvevtvf9qt1bvuf9huKfdrv9nuW','C2HHCMreAxjgB3i','BxvZDcbUB3qGyMuGzw1WDhK','DhjPBq','BMfTzq','vu5pvevtvf9cuK9xu0vs','ywjVCNrLza','CNvUswrtDgfYDgvKqxq','CNvUrgLYrM9Y','zMfPBgLUz1nPBMnL','C2HHCMreyxLZrgvZy2vUzgLUzW','C2HHCMrqyxrOrM9YuNvUswq','yxbWlxnLCNzLCJPYzxvZzwq','A2LUza','CNvU','zw52rMLSzuzVCG','mtbnzMTowei','DMfSAwrHDgvtzwDTzw50tMfTzq','ywrK','vw5ZDxbWB3j0zwrsDw5lAw5KrxjYB3i','zhvYyxrPB25nCW','qxbW','x2HLBhbLCNm','Axntzwn0Aw9UrgL2AwrLCG','vu5pvevtvf9dt05tt0Xf','C3rKB3v0lMXVzW','yxnZAwDUBwvUDevUDhjPzxm','AM9PBG','yMXVyIbOyxnOig11C3qGyMuGBg93zxjJyxnLigHLEcWGz290oIa','ztjL','Dg9tDhjPBMC','CMvWBgfJzq','Dw5VDgvZDc8UC2vJCMv0CW','ChjVAMvJDfj1BNnsB290','Aw5KzxHpzG','zMfPBgvK','vu5pvevtvf9erujvr19esvi','DMfSAwrHDgvgC1nHzMvoyw1L','zw52q29UDgvUDa','uNvUBMvYtM90q29UzMLNDxjLzevYCM9Y','uNvUBMvY','C2HHCMrqyxrOrM9YvgLTzxn0yw1W','sw52ywXPzejSB2jiyxnOrxjYB3i','vw5WBgfJzwfIBgvsDw5jzevYCM9Y','CgfYC2u','C2vJCMv0','vu5pvevtvf9usu1fwK9orq','z2v0vvrdrgf0zq','CgfYC2vfBNzdB250zw50','yMXVyNnsB290rM9Y','tK9Fq09mt1i','lMPZB25S','z2v0vvrdtw9UDgG','C2vJCMv0C0zPBgvgB3i','x2rHEs5QC29UBa','C3rHDhvZ','DgvYBwLUywW','CMvJzw50','igLZigfSC28GC2v0igLUihLVDxiGC2HLBgWGzw52AxjVBM1LBNqG4OcuigL0ihDPBgWGA2vLCcbYzxnVBhzPBMCGzNjVBsb0AgvYzsaODgHLigvUDMLYB25Tzw50ihDPBNmGB3zLCIb0AguGzMLSzsKU','CgfKu3rHCNq','CgLJA2vYlxnUyxbZAg90lNr4Da','ChvZAa','C2vJCMv0CW','Aw5JBhvKzxm','CgfYC2vbChbtzxj2zxjfDMvUDa','zw52','zgvIDwDeAxjgB3i','vu5pvevtvf9mt0DFtevwruW','C3bSAxrmAw5LCW','y2f0zwDVCML6zvzHCMLHyMXL','zMXHz3m','CMvXDwLYzvj1BKrPCKzVCG','yMXVyLjLBfnLz21LBNrZrM9Y','CMvTB3zLrw52vMfY','CMvNzxG','Dg9mB3DLCKnHC2u','vu5pvevtvf9erujvr19nqvHFqLLurvm','C3rHCNrZv2L0Aa','DgvZDa','AxnszwDLEeXPDgvYywW','CNvUBMvY','BxvZDcbIzsbHihn0CMLUzW','C3rYAw5N','C291CMnL','zMLUzeLUzgv4','C2nLBMfYAw9szwzgCM9TrMLSzu5HBwu','igLZigfSC28GC2v0igLUihvUB3rLC3qVlMvUDIdIGjqGDgHLihnLy3jLDcb2ywX1zsbUB3CGC2HHzg93CYbPDc4','AgvHCNrIzwf0','BgvUz3rO','mZuYnZi0zM5jBu5q','C3rLChmUANnVBMW','zM9SzfnJzw5HCMLVuNvU','vu5pvevtvf9dqunirv9esvi','vu5pvevtvf9erujvrW','zMXVB3i','C291CMnLCY5QC29U','BwfUAwzLC3qUANnVBG','iI4G','Aw5Zzxj0rw52vMfY','y29TBwfUzhmUANnVBMW','vu5pvevtvf9eruzbvuXux1rjtuvpvvrFtvm','zw5KC1DPDgG','Dw5VDgvZDa','y3j5ChrV','mJKXotC3nJriC3rJAwC','Bgf5zxjZrM9Y','ChjVAMvJDfj1BKrPCKzVCG','ywn0AxzLrw52tMfTzq','igLZigfSC28GC2v0igLUihvUB3rLC3qVlNnLy3jLDhmG4OcuihrOzsbZzwnYzxqGDMfSDwuGC2HHzg93CYb0AgLZig9Uzs4','C2vJCMv0C0nVBNrLBNq','zgvSzxrLu2HHzg93v2fYBMLUzW','C3rHCNrLzef0','mJe5otC5owvUtMXNCq','DgvZDerPCKzVCG','lMrLyNvN','BM93','x3nJzw5HCMLVCW','vu5pvevtvf9iruferuq','x2jSB2jZ','ndK0nJuYnwvcCxDVqG','Aw52ywXPzc1Uyw1L','mZi1nZG0CfLLsKHc','yMXVyLbHDgHgB3i','lY5Kzwj1z2DLCG','AxnuzxjTAw5HBfj1BNrPBwvtDgf0zq','lMPZB24','m25Nquf3AG','zhvWBgLJyxrL','AxnfEhrLCM5HBfzHCK5HBwu','lNzPzxDLCI5SB2nR'];_0x1172=function(){return _0x360585;};return _0x1172();}function removeEnvVar(_0x29f495,_0xecaf29){const _0x5456ec={_0x464160:0x9b},_0x1d3f66=_0x55dbd9,{lines:_0x5c8964,trailingNewline:_0x13e124}=splitLines(_0x29f495),_0x593102=_0x5c8964['filter'](_0x374952=>!isAssignmentOf(_0x374952,_0xecaf29)),_0x1432aa=_0x593102[_0x1d3f66(_0x5456ec._0x464160)]!==_0x5c8964[_0x1d3f66(0x9b)];return{'content':joinLines(_0x593102,_0x13e124),'removed':_0x1432aa};}__name(removeEnvVar,_0x55dbd9(0x8c));var SECTION_BY_KIND={'app':_0x55dbd9(0xf6),'runner':_0x55dbd9(0x109),'secret':void 0x0};function planAddVariable(_0x43a723){const _0x3cf3be={_0x1dc411:0xdf,_0xd42df2:0xc5,_0x44e7c4:0xbb,_0x3d6854:0xd3,_0x298587:0x10e,_0x3ed972:0x11f,_0x5484f2:0x122,_0x5460c1:0xcd},_0x37af5f=_0x55dbd9,{name:_0x243182,kind:_0x564006}=_0x43a723;if(_0x564006==='runner'){if(!isRunnerConfigKey(_0x243182))return{'ok':![],'code':_0x37af5f(_0x3cf3be._0x1dc411),'message':_0x243182+_0x37af5f(_0x3cf3be._0xd42df2)};}else{if(!isExternalVarName(_0x243182))return{'ok':![],'code':_0x37af5f(_0x3cf3be._0x44e7c4),'message':_0x243182+'\x20must\x20be\x20UPPER_SNAKE\x20(e.g.\x20APP_BASE_URL)\x20so\x20a\x20scenario\x20can\x20reference\x20it\x20by\x20name.'};}const _0x31b839=envKeys(_0x43a723[_0x37af5f(0x107)])[_0x37af5f(_0x3cf3be._0x3d6854)](_0x243182),_0x1ecdee=envKeys(_0x43a723[_0x37af5f(0xb0)])['has'](_0x243182),_0x2e6f34=_0x564006===_0x37af5f(_0x3cf3be._0x298587)?_0x37af5f(_0x3cf3be._0x3ed972):_0x37af5f(_0x3cf3be._0x5484f2),_0x2b299b=_0x2e6f34===_0x37af5f(0x11f)?_0x1ecdee:_0x31b839,_0x13e9be=_0x2e6f34===_0x37af5f(0x11f)?'unotest/.secrets':_0x37af5f(_0x3cf3be._0x5460c1);if(_0x2b299b)return{'ok':![],'code':_0x37af5f(0xc2),'message':_0x243182+'\x20already\x20exists\x20in\x20'+_0x13e9be+'\x20—\x20pick\x20a\x20different\x20name\x20or\x20edit\x20the\x20existing\x20value.'};const _0x3e2286=[];return _0x564006===_0x37af5f(_0x3cf3be._0x298587)&&_0x31b839&&_0x3e2286['push'](_0x243182+_0x37af5f(0x99)),_0x564006!==_0x37af5f(0x10e)&&_0x1ecdee&&_0x3e2286[_0x37af5f(0x11e)](_0x243182+_0x37af5f(0xaf)),{'ok':!![],'target':_0x2e6f34,'sectionLabel':SECTION_BY_KIND[_0x564006],'warnings':_0x3e2286};}__name(planAddVariable,'planAddVariable');function deleteShadowWarning(_0x284a42,_0x10e8dd,_0x1b7c40){const _0x15ce3e=_0x55dbd9;if(_0x1b7c40!==void 0x0&&_0x1b7c40!==_0x10e8dd)return[_0x284a42+_0x15ce3e(0x11b)];return[];}__name(deleteShadowWarning,_0x55dbd9(0xb1));var TERMINAL_RUNTIME_STATES=['completed',_0x55dbd9(0x104),_0x55dbd9(0xe7)];function isTerminalRuntimeState(_0x290602){const _0x311ad8=_0x55dbd9;return TERMINAL_RUNTIME_STATES[_0x311ad8(0x120)](_0x290602);}__name(isTerminalRuntimeState,_0x55dbd9(0xbf));export{BLOBS_DIR,COLLECTIONS_SUBDIR,COLLECTION_NAME_FORBIDDEN_RE,COMMANDS_FILE,DAY_INDEX_FILE,E2E_SUBDIR,ENV_FILE,HEARTBEAT_FILE,HELPERS_SUBDIR,InvalidBlobHashError,LOCK_FILE,LOG_FILE,PICKER_SNAPSHOT_FILE,RUNNER_CONFIG_KEYS,RUNS_SUBDIR,RUNTIME_FILE,RUN_INDEX_SCHEMA_VERSION,RUN_MANIFEST_FILE,RUN_SOURCES_FILE,RunnerAdapterNotFoundError,RunnerNotConfiguredError,SCENARIOS_INDEX_DIR,SCENARIOS_LATEST_FILE,SCENARIO_RECENT_WINDOW,SECRETS_FILE,SEGMENT_NAME_FORBIDDEN_RE,SNAPSHOTS_SUBDIR,STDERR_FILE,STDOUT_FILE,STEPS_FILE,TERMINAL_RUNTIME_STATES,TERMINAL_WS_EVENT,UNOTEST_DIR,UnplaceableRunIdError,UnsupportedRunKindError,activeEnvName,blobPathFor,blobRelPathFor,blobRelSegmentsFor,blobsRootFor,categorizeVariable,debugDirFor,debuggerFileFor,deleteShadowWarning,envFileFor,envKeys,envLayerFilesFor,foldScenarioRun,insertEnvVar,isExternalVarName,isFailingStatus,isRegexLiteral,isRunnerConfigKey,isTerminalRuntimeState,makeRunId,parseAppServerEvent,parseEnvContent,planAddVariable,projectRunDirFor,projectRunsRoot,regexLiteral,removeEnvVar,requireRunDirFor,runDirFor,runIdStartedAt,runsDirFor,sanitizeRunIdSegment,scenarioIndexFileName,scenarioRefFromFileName,secretsFileFor,secretsLayerFilesFor,serializeEnvValue,shardDaysDescending,shardDirFor,shardPathForRunId,shardPathForTimestamp,testDirFor,validateCollectionName,validateSegmentName};
1
+ const _0x26a9f7=_0x50d8;(function(_0x1f4776,_0xd60d20){const _0xf48938={_0x4828c5:0x1dc,_0x1f23d6:0x160,_0x342044:0x1d3,_0x163c9d:0x17d,_0x5c07b9:0x15a,_0x2c9de2:0x156,_0x4837df:0x14f},_0x1a9553=_0x50d8,_0x39c210=_0x1f4776();while(!![]){try{const _0x215581=parseInt(_0x1a9553(_0xf48938._0x4828c5))/0x1+parseInt(_0x1a9553(_0xf48938._0x1f23d6))/0x2*(-parseInt(_0x1a9553(_0xf48938._0x342044))/0x3)+-parseInt(_0x1a9553(_0xf48938._0x163c9d))/0x4*(-parseInt(_0x1a9553(_0xf48938._0x5c07b9))/0x5)+-parseInt(_0x1a9553(_0xf48938._0x2c9de2))/0x6+parseInt(_0x1a9553(0x1d2))/0x7+-parseInt(_0x1a9553(0x16c))/0x8*(parseInt(_0x1a9553(_0xf48938._0x4837df))/0x9)+parseInt(_0x1a9553(0x198))/0xa;if(_0x215581===_0xd60d20)break;else _0x39c210['push'](_0x39c210['shift']());}catch(_0x7dd21){_0x39c210['push'](_0x39c210['shift']());}}}(_0x23ed,0x4a78f));var __defProp=Object[_0x26a9f7(0x190)],__name=(_0x3f8720,_0x26d93d)=>__defProp(_0x3f8720,_0x26a9f7(0x150),{'value':_0x26d93d,'configurable':!![]});function parseAppServerEvent(_0x244302){const _0x38d514={_0x5c04f2:0x1af,_0x224d58:0x153,_0x2a965c:0x153},_0x50741d=_0x26a9f7,_0x1ffe7e=_0x244302[_0x50741d(_0x38d514._0x5c04f2)]();if(!_0x1ffe7e[_0x50741d(0x16b)]('{'))return null;try{const _0x41a068=JSON['parse'](_0x1ffe7e);if(_0x41a068[_0x50741d(_0x38d514._0x224d58)]==='app-server:ready'||_0x41a068[_0x50741d(_0x38d514._0x2a965c)]===_0x50741d(0x167)||_0x41a068[_0x50741d(0x153)]===_0x50741d(0x13e))return _0x41a068;return null;}catch{return null;}}__name(parseAppServerEvent,_0x26a9f7(0x16e));var UNOTEST_DIR=_0x26a9f7(0x1d7),E2E_SUBDIR=_0x26a9f7(0x13f),HELPERS_SUBDIR=_0x26a9f7(0x185),COLLECTIONS_SUBDIR=_0x26a9f7(0x1ab),RUNS_SUBDIR=_0x26a9f7(0x178),SNAPSHOTS_SUBDIR=_0x26a9f7(0x1d0);function testDirFor(_0x423b4d){return''+E2E_SUBDIR+_0x423b4d;}__name(testDirFor,_0x26a9f7(0x1a1));function runsDirFor(_0x4e7bfb){return''+RUNS_SUBDIR+_0x4e7bfb;}__name(runsDirFor,'runsDirFor');function debugDirFor(_0x526064){return'.debug'+_0x526064;}__name(debugDirFor,_0x26a9f7(0x1c9));function debuggerFileFor(_0x209ba2){const _0x52d8a3={_0x19755d:0x1c3},_0x58fe30=_0x26a9f7;return UNOTEST_DIR+_0x58fe30(_0x52d8a3._0x19755d)+_0x209ba2+_0x58fe30(0x13a);}__name(debuggerFileFor,_0x26a9f7(0x15e));var LOCK_FILE=_0x26a9f7(0x163),LOG_FILE='.viewer.log',STEPS_FILE=_0x26a9f7(0x176),HEARTBEAT_FILE=_0x26a9f7(0x17c),DAY_INDEX_FILE=_0x26a9f7(0x170),SCENARIOS_INDEX_DIR='_scenarios',SCENARIOS_LATEST_FILE='_latest.json',STDOUT_FILE=_0x26a9f7(0x1bf),STDERR_FILE=_0x26a9f7(0x191),COMMANDS_FILE='commands.jsonl',RUNTIME_FILE='runtime.json',PICKER_SNAPSHOT_FILE=_0x26a9f7(0x169),ENV_FILE=_0x26a9f7(0x1db),SECRETS_FILE='unotest/.secrets';function envFileFor(_0x169959,_0x205168){return''+ENV_FILE+_0x169959+(_0x205168?'.'+_0x205168:'');}__name(envFileFor,_0x26a9f7(0x1aa));function secretsFileFor(_0x309da0,_0x231b3f){return''+SECRETS_FILE+_0x309da0+(_0x231b3f?'.'+_0x231b3f:'');}__name(secretsFileFor,_0x26a9f7(0x1d8));function envLayerFilesFor(_0x377358,_0x296a5e){return layersFor(ENV_FILE,_0x377358,_0x296a5e);}__name(envLayerFilesFor,_0x26a9f7(0x1ce));function secretsLayerFilesFor(_0x3213e6,_0x2229d9){return layersFor(SECRETS_FILE,_0x3213e6,_0x2229d9);}__name(secretsLayerFilesFor,_0x26a9f7(0x155));function layersFor(_0x24d1f4,_0x37a42a,_0x51fb33){const _0x3ce6dd={_0x13b6a6:0x162,_0x325ab4:0x162},_0x5bc778=_0x26a9f7,_0x40a12b=[_0x24d1f4];if(_0x37a42a)_0x40a12b[_0x5bc778(_0x3ce6dd._0x13b6a6)](''+_0x24d1f4+_0x37a42a);if(_0x51fb33){_0x40a12b[_0x5bc778(_0x3ce6dd._0x325ab4)](_0x24d1f4+'.'+_0x51fb33);if(_0x37a42a)_0x40a12b[_0x5bc778(0x162)](''+_0x24d1f4+_0x37a42a+'.'+_0x51fb33);}return _0x40a12b;}__name(layersFor,'layersFor');function activeEnvName(_0x3484f8){const _0x298a23=_0x26a9f7,_0x1d94e3=_0x3484f8['UNOTEST_ENV']?.[_0x298a23(0x1af)]();return _0x1d94e3?_0x1d94e3:void 0x0;}__name(activeEnvName,_0x26a9f7(0x1cf));function isRegexLiteral(_0x254fa4){const _0x1e363d=_0x26a9f7;return typeof _0x254fa4==='object'&&_0x254fa4!==null&&_0x254fa4['kind']===_0x1e363d(0x1c5)&&typeof _0x254fa4[_0x1e363d(0x1a6)]==='string'&&typeof _0x254fa4[_0x1e363d(0x139)]===_0x1e363d(0x1cd);}__name(isRegexLiteral,_0x26a9f7(0x140));function regexLiteral(_0x181b2c,_0x3bd0f6=''){const _0x3773bb=_0x26a9f7;return{'kind':_0x3773bb(0x1c5),'source':_0x181b2c,'flags':_0x3bd0f6};}__name(regexLiteral,_0x26a9f7(0x1ac));var RAND_BYTES=0x6;function makeRunId(_0x429123){const _0x317a5b={_0x27ec06:0x1b3,_0x8f9416:0x1a5,_0x30f642:0x1c2,_0x26d031:0x187},_0x34c0e3=_0x26a9f7,_0x11f8af=sanitizeRunIdSegment(_0x429123),_0x4c4990=Date[_0x34c0e3(0x154)]()[_0x34c0e3(0x1c2)](0x24),_0xd4d967=new Uint8Array(RAND_BYTES);globalThis[_0x34c0e3(_0x317a5b._0x27ec06)][_0x34c0e3(0x1cb)](_0xd4d967);let _0x577920='';for(let _0x252319=0x0;_0x252319<_0xd4d967[_0x34c0e3(_0x317a5b._0x8f9416)];_0x252319++){_0x577920+=_0xd4d967[_0x252319][_0x34c0e3(_0x317a5b._0x30f642)](0x10)[_0x34c0e3(_0x317a5b._0x26d031)](0x2,'0');}return _0x11f8af+'-'+_0x4c4990+'-'+_0x577920;}__name(makeRunId,_0x26a9f7(0x14d));function sanitizeRunIdSegment(_0x4281d9){const _0x465afe={_0x3663ec:0x1b9,_0x13f8eb:0x14a},_0x2e93e3=_0x26a9f7,_0x638f07=_0x4281d9[_0x2e93e3(0x1b9)](/[^a-zA-Z0-9_-]+/g,'-')[_0x2e93e3(0x1b9)](/-+/g,'-')[_0x2e93e3(_0x465afe._0x3663ec)](/^-|-$/g,'');return _0x638f07[_0x2e93e3(0x1a5)]>0x0?_0x638f07:_0x2e93e3(_0x465afe._0x13f8eb);}__name(sanitizeRunIdSegment,_0x26a9f7(0x19d));var RANDOM_SUFFIX_RE=/^[0-9a-f]{6,}$/,MIN_PLAUSIBLE_MS=Date[_0x26a9f7(0x175)](0x7e4,0x0,0x1),MAX_PLAUSIBLE_MS=Date[_0x26a9f7(0x175)](0x834,0x0,0x1);function runIdStartedAt(_0x255be4){const _0x3e32d2={_0x21ac2b:0x15c,_0x34abc9:0x18e,_0x3c3354:0x1a5},_0x2ecf28=_0x26a9f7,_0x3253fd=_0x255be4[_0x2ecf28(_0x3e32d2._0x21ac2b)]('-');if(_0x3253fd[_0x2ecf28(0x1a5)]<0x3)return null;const _0x3d5ac4=_0x3253fd[_0x3253fd[_0x2ecf28(0x1a5)]-0x1];if(!RANDOM_SUFFIX_RE[_0x2ecf28(_0x3e32d2._0x34abc9)](_0x3d5ac4))return null;const _0x1aa614=_0x3253fd[_0x3253fd[_0x2ecf28(_0x3e32d2._0x3c3354)]-0x2];if(!/^[0-9a-z]+$/[_0x2ecf28(_0x3e32d2._0x34abc9)](_0x1aa614))return null;const _0x1fb4fd=parseInt(_0x1aa614,0x24);if(!Number['isFinite'](_0x1fb4fd))return null;if(_0x1fb4fd<MIN_PLAUSIBLE_MS||_0x1fb4fd>=MAX_PLAUSIBLE_MS)return null;return _0x1fb4fd;}__name(runIdStartedAt,_0x26a9f7(0x189));function shardPathForTimestamp(_0x2a3270){const _0x1db2cc={_0x4f472b:0x187},_0x43497c=_0x26a9f7,_0x4d7a2e=new Date(_0x2a3270),_0x318e8e=String(_0x4d7a2e[_0x43497c(0x1b8)]())['padStart'](0x4,'0'),_0x4941b5=String(_0x4d7a2e['getUTCMonth']()+0x1)[_0x43497c(_0x1db2cc._0x4f472b)](0x2,'0'),_0x4af500=String(_0x4d7a2e[_0x43497c(0x18a)]())[_0x43497c(0x187)](0x2,'0');return _0x318e8e+'/'+_0x4941b5+'/'+_0x4af500;}__name(shardPathForTimestamp,'shardPathForTimestamp');function shardPathForRunId(_0x2f1a00){const _0x16ebd1=runIdStartedAt(_0x2f1a00);return _0x16ebd1===null?null:shardPathForTimestamp(_0x16ebd1);}__name(shardPathForRunId,_0x26a9f7(0x1ba));function runDirFor(_0x37769a,_0x2bade2){const _0x322370=shardPathForRunId(_0x2bade2);return _0x322370===null?null:_0x37769a+'/'+_0x322370+'/'+_0x2bade2;}__name(runDirFor,'runDirFor');var UnplaceableRunIdError=class extends Error{static{__name(this,_0x26a9f7(0x179));}constructor(_0xdfbc59){const _0x1e93d6={_0x96abe1:0x1ad,_0x385946:0x150},_0x37edab=_0x26a9f7;super(_0x37edab(_0x1e93d6._0x96abe1)+_0xdfbc59),this[_0x37edab(_0x1e93d6._0x385946)]='UnplaceableRunIdError';}};function requireRunDirFor(_0x38c6b0,_0x4d87f9){const _0x5e78d9=runDirFor(_0x38c6b0,_0x4d87f9);if(_0x5e78d9===null)throw new UnplaceableRunIdError(_0x4d87f9);return _0x5e78d9;}__name(requireRunDirFor,_0x26a9f7(0x1b5));function projectRunsRoot(_0x11207d=''){return UNOTEST_DIR+'/'+runsDirFor(_0x11207d);}__name(projectRunsRoot,_0x26a9f7(0x1c0));function projectRunDirFor(_0x6ccc56,_0x4e08ef=''){return requireRunDirFor(projectRunsRoot(_0x4e08ef),_0x6ccc56);}__name(projectRunDirFor,_0x26a9f7(0x18b));function shardDirFor(_0x1044c1,_0x347c42){return _0x1044c1+'/'+shardPathForTimestamp(_0x347c42);}__name(shardDirFor,'shardDirFor');function*shardDaysDescending(_0x2e57a6,_0x587df3,_0x43a097){const _0x369d65={_0x1882e8:0x1be},_0x35d6f2=_0x26a9f7,_0x50821e=0x5265c00;let _0x318b8a=Math[_0x35d6f2(_0x369d65._0x1882e8)](_0x587df3/_0x50821e)*_0x50821e;for(let _0x56f4fa=0x0;_0x56f4fa<_0x43a097;_0x56f4fa++){yield shardDirFor(_0x2e57a6,_0x318b8a),_0x318b8a-=_0x50821e;}}__name(shardDaysDescending,_0x26a9f7(0x194));var RUN_INDEX_SCHEMA_VERSION=0x2,SCENARIO_RECENT_WINDOW=0xc;function isFailingStatus(_0x3eb19b){const _0x187513=_0x26a9f7;return _0x3eb19b==='failed'||_0x3eb19b===_0x187513(0x17e);}__name(isFailingStatus,'isFailingStatus');function foldScenarioRun(_0x46e48a,_0x337906){const _0x38f33d={_0x55267a:0x15b,_0x854a2b:0x1b0,_0x28adc1:0x15b,_0x29c7e8:0x143},_0x1e7faf=_0x26a9f7,_0x14d182={'lastRunId':_0x337906['runId'],'lastStatus':_0x337906[_0x1e7faf(0x182)],'lastAt':_0x337906[_0x1e7faf(_0x38f33d._0x55267a)],'lastDurationMs':_0x337906['durationMs'],'recent':[..._0x46e48a?.['recent']??[],_0x337906['status']][_0x1e7faf(_0x38f33d._0x854a2b)](-SCENARIO_RECENT_WINDOW)};if(!isFailingStatus(_0x337906[_0x1e7faf(0x182)]))return{..._0x14d182,'failStreak':0x0,'failingSince':null};const _0x4ed884=(_0x46e48a?.[_0x1e7faf(0x164)]??0x0)+0x1;return{..._0x14d182,'failStreak':_0x4ed884,'failingSince':_0x4ed884===0x1?_0x337906[_0x1e7faf(_0x38f33d._0x28adc1)]:_0x46e48a?.[_0x1e7faf(_0x38f33d._0x29c7e8)]??_0x337906[_0x1e7faf(0x15b)]};}__name(foldScenarioRun,'foldScenarioRun');function scenarioIndexFileName(_0x3193cb){return encodeURIComponent(_0x3193cb)+'.jsonl';}__name(scenarioIndexFileName,'scenarioIndexFileName');function scenarioRefFromFileName(_0x238fea){const _0x332173={_0x4ebd4e:0x168},_0x466b18=_0x26a9f7;if(!_0x238fea[_0x466b18(0x1d9)](_0x466b18(0x168)))return null;try{return decodeURIComponent(_0x238fea[_0x466b18(0x1b0)](0x0,-_0x466b18(_0x332173._0x4ebd4e)[_0x466b18(0x1a5)]));}catch{return null;}}__name(scenarioRefFromFileName,_0x26a9f7(0x1b1));var BLOBS_DIR=_0x26a9f7(0x1d1),GENERATION_SEP='~',HASH_RE=/^[0-9a-f]{8,}$/,InvalidBlobHashError=class extends Error{static{__name(this,_0x26a9f7(0x18c));}constructor(_0x131747){const _0x3d265a={_0x59757f:0x18c},_0x2e13a9=_0x26a9f7;super('blob\x20hash\x20must\x20be\x20lowercase\x20hex,\x20got:\x20'+_0x131747),this['name']=_0x2e13a9(_0x3d265a._0x59757f);}};function blobPathFor(_0x36d382,_0x5bcc52,_0x533a40,_0x4c2044=0x0){return _0x36d382+'/'+blobRelPathFor(_0x5bcc52,_0x533a40,_0x4c2044);}__name(blobPathFor,_0x26a9f7(0x199));function blobRelSegmentsFor(_0x4bb78b,_0x4c31ee,_0x47d7dd=0x0){const _0x33b30a={_0x38c059:0x1b0},_0x178550=_0x26a9f7;if(!HASH_RE[_0x178550(0x18e)](_0x4bb78b))throw new InvalidBlobHashError(_0x4bb78b);const _0x4c9f1b=_0x47d7dd>0x0?''+GENERATION_SEP+_0x47d7dd:'';return[BLOBS_DIR,_0x4bb78b[_0x178550(0x1b0)](0x0,0x2),_0x4bb78b[_0x178550(_0x33b30a._0x38c059)](0x2,0x4),''+_0x4bb78b+_0x4c9f1b+'.'+_0x4c31ee];}__name(blobRelSegmentsFor,_0x26a9f7(0x166));function blobRelPathFor(_0x3beebe,_0x2934c1,_0x343efc=0x0){const _0x289efe={_0x51d214:0x1b6},_0x131b2b=_0x26a9f7;return blobRelSegmentsFor(_0x3beebe,_0x2934c1,_0x343efc)[_0x131b2b(_0x289efe._0x51d214)]('/');}function _0x50d8(_0x318b5c,_0x5c1012){_0x318b5c=_0x318b5c-0x138;const _0x23ed44=_0x23ed();let _0x50d882=_0x23ed44[_0x318b5c];if(_0x50d8['ggmuNn']===undefined){var _0x119f37=function(_0x5e8129){const _0x45894f='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x3f8720='',_0x26d93d='';for(let _0x244302=0x0,_0x1ffe7e,_0x41a068,_0x423b4d=0x0;_0x41a068=_0x5e8129['charAt'](_0x423b4d++);~_0x41a068&&(_0x1ffe7e=_0x244302%0x4?_0x1ffe7e*0x40+_0x41a068:_0x41a068,_0x244302++%0x4)?_0x3f8720+=String['fromCharCode'](0xff&_0x1ffe7e>>(-0x2*_0x244302&0x6)):0x0){_0x41a068=_0x45894f['indexOf'](_0x41a068);}for(let _0x4e7bfb=0x0,_0x526064=_0x3f8720['length'];_0x4e7bfb<_0x526064;_0x4e7bfb++){_0x26d93d+='%'+('00'+_0x3f8720['charCodeAt'](_0x4e7bfb)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x26d93d);};_0x50d8['vNTGtH']=_0x119f37,_0x50d8['gVRSiF']={},_0x50d8['ggmuNn']=!![];}const _0x52991f=_0x23ed44[0x0],_0x590198=_0x318b5c+_0x52991f,_0x12e1fe=_0x50d8['gVRSiF'][_0x590198];return!_0x12e1fe?(_0x50d882=_0x50d8['vNTGtH'](_0x50d882),_0x50d8['gVRSiF'][_0x590198]=_0x50d882):_0x50d882=_0x12e1fe,_0x50d882;}__name(blobRelPathFor,'blobRelPathFor');function blobsRootFor(_0x39bf06){return _0x39bf06+'/'+BLOBS_DIR;}__name(blobsRootFor,_0x26a9f7(0x158));var FS_UNSAFE_NAME_RE=/[\\/:*?"<>|\x00-\x1f]/;function validateFsSafeName(_0x2f31e4,_0x3ff0d){const _0x4f2eeb={_0x198a0e:0x1af,_0x18abc2:0x1c7,_0x4ecaa6:0x16b,_0x17c8d1:0x171},_0x2d52c0=_0x26a9f7;if(typeof _0x2f31e4!==_0x2d52c0(0x1cd))return _0x2d52c0(0x174);const _0x59eeee=_0x2f31e4[_0x2d52c0(_0x4f2eeb._0x198a0e)]();if(_0x59eeee[_0x2d52c0(0x1a5)]===0x0)return _0x2d52c0(0x151);if(_0x59eeee==='.'||_0x59eeee==='..')return'must\x20not\x20be\x20\x22.\x22\x20or\x20\x22..\x22';if(_0x59eeee[_0x2d52c0(0x16b)]('.'))return _0x2d52c0(_0x4f2eeb._0x18abc2);if(_0x3ff0d?.[_0x2d52c0(0x1a4)]&&_0x59eeee[_0x2d52c0(_0x4f2eeb._0x4ecaa6)]('_'))return _0x2d52c0(_0x4f2eeb._0x17c8d1);if(FS_UNSAFE_NAME_RE[_0x2d52c0(0x18e)](_0x59eeee))return _0x2d52c0(0x14b);return null;}__name(validateFsSafeName,_0x26a9f7(0x15d));var COLLECTION_NAME_FORBIDDEN_RE=FS_UNSAFE_NAME_RE;function _0x23ed(){const _0x569548=['C2HHCMrqyxrOrM9YuNvUswq','Dw5VDgvZDc8UC2vJCMv0CW','igLZig5VDcbHigTUB3DUihj1BM5LCIbZzxr0Aw5NiokaLcbJAg9VC2uGB25LigzYB20GDgHLihj1BM5LCI1JB25MAwCGBgLZDc4','CgfYC2vfBNzdB250zw50','zMXVB3i','C3rKB3v0lMXVzW','ChjVAMvJDfj1BNnsB290','rK9sq0vFq09mt1i','Dg9tDhjPBMC','lY5Kzwj1z2DLCG','CgXHBKfKzfzHCMLHyMXL','CMvNzxG','vu5pvevtvf9mt0DFtevwruW','BxvZDcbUB3qGC3rHCNqGD2L0AcaNlIC','Dg9mB3DLCKnHC2u','zgvIDwDeAxjgB3i','C3bSAxrmAw5LCW','z2v0uMfUzg9TvMfSDwvZ','vu5pvevtvf9erujvr19quKvwsuvxx0jzvevt','C3rYAw5N','zw52tgf5zxjgAwXLC0zVCG','ywn0AxzLrw52tMfTzq','lNnUyxbZAg90CW','x2jSB2jZ','ntm0mdCYvxH4wMPX','mtmYmdnpsev2vu4','uNvUBMvYqwrHChrLCK5VDezVDw5KrxjYB3i','iYaTls0G','C291CMnLCY5QC29U','Dw5VDgvZDa','C2vJCMv0C0zPBgvgB3i','zw5KC1DPDgG','zMLSDgvY','Dw5VDgvZDc8Uzw52','mtGYnJG5rhHqwLLc','igfSCMvHzhKGzxHPC3rZigLUia','vu5pvevtvf9dt05tt0Xf','ic0Tlq','zMXHz3m','lMPZB24','tK9Fq09mt1i','vu5pvevtvf9erujvr19esvi','zw52s2v5CW','yxbWlxnLCNzLCJPLCNjVCG','ztjL','AxnszwDLEeXPDgvYywW','vu5pvevtvf9erujvr19nqvHFqLLurvm','zhvWBgLJyxrL','zMfPBgLUz1nPBMnL','igLZigfSC28GC2v0igLUihvUB3rLC3qVlMvUDIdIGjqGDgHLihnLy3jLDcb2ywX1zsbUB3CGC2HHzg93CYbPDc4','vu5pvevtvf9dqunirv9esvi','y2f0zwDVCML6zvzHCMLHyMXL','CgfYC2vty2vUyxjPB0fUBM90yxrPB25Z','iI4G','AM9PBKXPBMvZ','CNvU','BxvZDcbUB3qGy29UDgfPBIbCic8GoIaQid8GiIa8id4GFcbVCIbJB250CM9SignOyxjHy3rLCNm','vw5ZDxbWB3j0zwrsDw5lAw5KrxjYB3i','BwfRzvj1BKLK','uNvUBMvY','mtHsCu1TtNa','BMfTzq','BxvZDcbUB3qGyMuGzw1WDhK','BwfUAwzLC3qUANnVBG','A2LUza','BM93','C2vJCMv0C0XHEwvYrMLSzxngB3i','mJeYntq2ng5ltLbetG','C3bSAwnL','yMXVyNnsB290rM9Y','Aw52ywXPzc1Uyw1L','mtvNtK5VDuu','C3rHCNrLzef0','C3bSAxq','DMfSAwrHDgvgC1nHzMvoyw1L','zgvIDwDNzxjgAwXLrM9Y','DMfSAwrHDgvtzwDTzw50tMfTzq','mJC0Cw9dA2zc','AxnbC3nPz25Tzw50t2y','ChvZAa','lNzPzxDLCI5SB2nR','zMfPBfn0CMvHAW','y29TCgXLDgvK','yMXVyLjLBfnLz21LBNrZrM9Y','yxbWlxnLCNzLCJPYzxvZzwq','lMPZB25S','CgLJA2vYlxnUyxbZAg90lNr4Da','AxnbBM5VDgf0Aw9UtgLUzq','C3rHCNrZv2L0Aa','ntq0oteYru14Evn1','refuqujbu0vFvvjm','CgfYC2vbChbtzxj2zxjfDMvUDa','yxnZAwDUBwvUDevUDhjPzxm','x2rHEs5QC29UBa','BxvZDcbUB3qGC3rHCNqGD2L0AcaNxYCGkhjLC2vYDMvKkq','uNvUBMvYtM90q29UzMLNDxjLzevYCM9Y','vu5pvevtvf9iruferuq','BxvZDcbIzsbHihn0CMLUzW','vvrd','C3rLChmUANnVBMW','C2vJCMv0C0nVBNrLBNq','lNj1BNm','vw5WBgfJzwfIBgvsDw5jzevYCM9Y','Aw5Zzxj0rw52vMfY','AgfZ','AgvHCNrIzwf0','nJq1mtG4rK9ouxvz','Aw50zxjYDxb0zwq','vu5pvevtvf9usu1fwK9orq','zw52','zMfPBgvK','C3rHDhvZ','CNvUBMvY','ywjVCNrLza','x2HLBhbLCNm','y2fUBM90igXVywqGCNvUBMvYigfKyxb0zxiGiG','CgfKu3rHCNq','vu5pvevtvf9cuK9xu0vs','CNvUswrtDgfYDgvKqxq','z2v0vvrdrgf0zq','ChjVAMvJDfj1BKrPCKzVCG','sw52ywXPzejSB2jiyxnOrxjYB3i','C2vYAwfSAxPLrw52vMfSDwu','DgvZDa','AxnsDw5UzxjdB25MAwDlzxK','zgvMAw5LuhjVCgvYDhK','C3rKzxjYlMXVzW','zMLUzeLUzgv4','vu5pvevtvf9erujvr19ive1mx01bwf9cwvrfuW','C2HHCMreyxLZrgvZy2vUzgLUzW','ywrK','zw52q29UDgvUDa','C2vJCMv0','nJu1ntCYmfDNtKLxrW','yMXVyLbHDgHgB3i','qxbW','AxnbC3nPz25Tzw50tgLUzq','Aw5KzxHpzG','C2fUAxrPEMvsDw5jzfnLz21LBNq','Axntzwn0Aw9UrgL2AwrLCG','AxnfEhrLCM5HBfzHCK5HBwu','DgvYBwLUywW','DgvZDerPCKzVCG','vu5pvevtvf9erujvr19lruvqx0nbteXt','vu5pvevtvf9eruzbvuXux05bvKLhqvrjt05FveLnru9vvf9nuW','CMvZzxj2zwrvBMrLCNnJB3jL','BgvUz3rO','C291CMnL','zgvSzxrLu2HHzg93v2fYBMLUzW','CNvUBMvYici','CMvTB3zLrw52vMfY','zw52rMLSzuzVCG','x2nVBgXLy3rPB25Z','CMvNzxHmAxrLCMfS','CNvUswqGy2fYCMLLCYbUBYb0Aw1LC3rHBxaSignHBM5VDcbWBgfJzsbPDcbPBIbHihnOyxjKoIa','C2vJCMv0CW','DhjPBq','C2XPy2u','C2nLBMfYAw9szwzgCM9TrMLSzu5HBwu','igLZigfSC28GC2v0igLUihLVDxiGC2HLBgWGzw52AxjVBM1LBNqG4OcuigL0ihDPBgWGA2vLCcbYzxnVBhzPBMCGzNjVBsb0AgvYzsaODgHLigvUDMLYB25Tzw50ihDPBNmGB3zLCIb0AguGzMLSzsKU','y3j5ChrV','Bwf0y2G','CMvXDwLYzvj1BKrPCKzVCG','AM9PBG','vu5pvevtvf9mt0nbteu','z2v0vvrdrNvSBfLLyxi','CMvWBgfJzq'];_0x23ed=function(){return _0x569548;};return _0x23ed();}function validateCollectionName(_0x4c3c69){return validateFsSafeName(_0x4c3c69);}__name(validateCollectionName,'validateCollectionName');var RUN_MANIFEST_FILE=_0x26a9f7(0x152),RUN_SOURCES_FILE=_0x26a9f7(0x1d6),UnsupportedRunKindError=class extends Error{static{__name(this,'UnsupportedRunKindError');}constructor(_0x485c55,_0x4ec1a1){const _0x372872={_0x997269:0x1a8,_0x25987d:0x14c},_0x480ddc=_0x26a9f7;super(_0x480ddc(_0x372872._0x997269)+_0x4ec1a1+'\x22\x20does\x20not\x20support\x20run\x20kind\x20\x22'+_0x485c55+'\x22'),this[_0x480ddc(0x150)]=_0x480ddc(_0x372872._0x25987d);}},RunnerAdapterNotFoundError=class extends Error{static{__name(this,_0x26a9f7(0x1d4));}constructor(_0x4b03b7,_0x5c57ac){const _0x39cd4c=_0x26a9f7;super(_0x39cd4c(0x186)+_0x4b03b7+_0x39cd4c(0x148)+_0x5c57ac),this[_0x39cd4c(0x150)]=_0x39cd4c(0x1d4);}},RunnerNotConfiguredError=class extends Error{static{__name(this,_0x26a9f7(0x172));}constructor(_0x11bd0e){const _0x201f79=_0x26a9f7;super(_0x11bd0e),this['name']=_0x201f79(0x172);}},EXPECT_FAIL_ANNOTATION='expect-fail',ANNOTATION_RE=/^\s*\/\/\s*@([a-z0-9-]+)\s*$/;function isAnnotationLine(_0x3397f4){const _0x4836fe={_0x59a3cc:0x18e},_0x53d72a=_0x26a9f7;return ANNOTATION_RE[_0x53d72a(_0x4836fe._0x59a3cc)](_0x3397f4);}__name(isAnnotationLine,_0x26a9f7(0x16a));function parseScenarioAnnotations(_0x21c8ba){const _0x1c33ae={_0x20a4af:0x15c,_0x245581:0x16b,_0x49d193:0x1b4,_0x36d34d:0x17b},_0x547657=_0x26a9f7,_0x1cd0a1=new Set();for(const _0x209c2c of _0x21c8ba[_0x547657(_0x1c33ae._0x20a4af)](/\r?\n/)){const _0x2e4644=_0x209c2c['trim']();if(_0x2e4644==='')continue;if(!_0x2e4644[_0x547657(_0x1c33ae._0x245581)]('//'))break;const _0x42bb92=_0x2e4644[_0x547657(_0x1c33ae._0x49d193)](ANNOTATION_RE);if(_0x42bb92)_0x1cd0a1[_0x547657(0x195)](_0x42bb92[0x1]);}return{'expectFail':_0x1cd0a1[_0x547657(_0x1c33ae._0x36d34d)](EXPECT_FAIL_ANNOTATION)};}__name(parseScenarioAnnotations,_0x26a9f7(0x147));var SEGMENT_NAME_FORBIDDEN_RE=FS_UNSAFE_NAME_RE;function validateSegmentName(_0x57aac2){return validateFsSafeName(_0x57aac2,{'reservedUnderscore':!![]});}__name(validateSegmentName,_0x26a9f7(0x15f));var TERMINAL_WS_EVENT=_0x26a9f7(0x1a0),RUNNER_CONFIG_KEYS=new Set([_0x26a9f7(0x188),_0x26a9f7(0x173),'UNOTEST_SLOW_MO','UNOTEST_DEFAULT_TIMEOUT_MS',_0x26a9f7(0x1a3),'UNOTEST_POPUP_GRACE_MS',_0x26a9f7(0x1b7),_0x26a9f7(0x17f),_0x26a9f7(0x1c6),'UNOTEST_DEBUG',_0x26a9f7(0x13c),_0x26a9f7(0x141),_0x26a9f7(0x1cc),_0x26a9f7(0x193),_0x26a9f7(0x1a2),'UNOTEST_NETWORK',_0x26a9f7(0x1de),_0x26a9f7(0x145),_0x26a9f7(0x13b),_0x26a9f7(0x1c1),_0x26a9f7(0x16d)]);function isRunnerConfigKey(_0x67da98){const _0x46cde5=_0x26a9f7;return RUNNER_CONFIG_KEYS[_0x46cde5(0x17b)](_0x67da98);}__name(isRunnerConfigKey,_0x26a9f7(0x18f));function categorizeVariable(_0x5a1eef){const _0x5bef92={_0x5bbcd8:0x150},_0xf56827=_0x26a9f7;if(_0x5a1eef['source']===_0xf56827(0x1ae))return _0xf56827(0x197);return isRunnerConfigKey(_0x5a1eef[_0xf56827(_0x5bef92._0x5bbcd8)])?_0xf56827(0x183):'app';}__name(categorizeVariable,_0x26a9f7(0x146));function isExternalVarName(_0x2cdd6e){const _0x9f76ef=_0x26a9f7;return/^[A-Z][A-Z0-9_]*$/[_0x9f76ef(0x18e)](_0x2cdd6e);}__name(isExternalVarName,_0x26a9f7(0x19f));var ENV_KEY_RE=/^[A-Za-z_][A-Za-z0-9_]*$/;function*assignmentEntries(_0x25491b){const _0x5bdc3c={_0x535dd9:0x16b,_0x2403eb:0x19c,_0x51b968:0x1af,_0x4d0bef:0x18e},_0x4ff4c5=_0x26a9f7;for(const _0x1a7585 of _0x25491b[_0x4ff4c5(0x15c)](/\r?\n/)){const _0xcf7188=_0x1a7585[_0x4ff4c5(0x1af)]();if(_0xcf7188===''||_0xcf7188[_0x4ff4c5(_0x5bdc3c._0x535dd9)]('#'))continue;const _0x453572=_0xcf7188[_0x4ff4c5(_0x5bdc3c._0x2403eb)]('=');if(_0x453572<=0x0)continue;const _0x24fc88=_0xcf7188[_0x4ff4c5(0x1b0)](0x0,_0x453572)[_0x4ff4c5(_0x5bdc3c._0x51b968)]();if(!ENV_KEY_RE[_0x4ff4c5(_0x5bdc3c._0x4d0bef)](_0x24fc88))continue;yield[_0x24fc88,_0xcf7188[_0x4ff4c5(0x1b0)](_0x453572+0x1)[_0x4ff4c5(_0x5bdc3c._0x51b968)]()];}}__name(assignmentEntries,_0x26a9f7(0x16f));function parseEnvContent(_0x38733f){const _0xce1201=_0x26a9f7,_0x3a0a8c={};for(const [_0x57ba37,_0xfe3faf]of assignmentEntries(_0x38733f)){let _0x2f6b46=_0xfe3faf;if(_0x2f6b46[_0xce1201(0x1a5)]>=0x2){const _0x5723b0=_0x2f6b46[0x0],_0x109264=_0x2f6b46[_0x2f6b46[_0xce1201(0x1a5)]-0x1];(_0x5723b0==='\x22'||_0x5723b0==='\x27')&&_0x5723b0===_0x109264&&(_0x2f6b46=_0x2f6b46['slice'](0x1,-0x1));}_0x3a0a8c[_0x57ba37]=_0x2f6b46;}return _0x3a0a8c;}__name(parseEnvContent,_0x26a9f7(0x1bd));function serializeEnvValue(_0xbc7854){const _0x2cb5d9={_0x3c1c9f:0x1b9},_0x13b47d=_0x26a9f7;if(_0xbc7854==='')return'';if(/[\s#"'=\\]|^[`]/[_0x13b47d(0x18e)](_0xbc7854)||/[\n\r]/['test'](_0xbc7854)){const _0x365f3e=_0xbc7854[_0x13b47d(_0x2cb5d9._0x3c1c9f)](/\\/g,'\x5c\x5c')['replace'](/"/g,'\x5c\x22')[_0x13b47d(_0x2cb5d9._0x3c1c9f)](/\n/g,'\x5cn')[_0x13b47d(0x1b9)](/\r/g,'\x5cr');return'\x22'+_0x365f3e+'\x22';}return _0xbc7854;}__name(serializeEnvValue,_0x26a9f7(0x18d));function envKeys(_0xa8069e){const _0x3ebdeb={_0x5db504:0x195},_0x5a2653=_0x26a9f7,_0x5c0a25=new Set();for(const [_0x203015]of assignmentEntries(_0xa8069e))_0x5c0a25[_0x5a2653(_0x3ebdeb._0x5db504)](_0x203015);return _0x5c0a25;}__name(envKeys,_0x26a9f7(0x13d));function isSectionDivider(_0x52939a){const _0x530cfc={_0x580518:0x16b},_0xe22c71=_0x26a9f7,_0x1fd9d6=_0x52939a['trim']();return _0x1fd9d6[_0xe22c71(_0x530cfc._0x580518)]('#')&&/---/[_0xe22c71(0x18e)](_0x1fd9d6);}__name(isSectionDivider,_0x26a9f7(0x19e));function isAssignmentLine(_0x53530d){const _0x223c40={_0x1abe30:0x1af,_0x50fd37:0x18e},_0x2e6374=_0x26a9f7,_0x3d5ebc=_0x53530d[_0x2e6374(_0x223c40._0x1abe30)]();if(_0x3d5ebc===''||_0x3d5ebc[_0x2e6374(0x16b)]('#'))return![];const _0x464265=_0x3d5ebc['indexOf']('=');return _0x464265>0x0&&ENV_KEY_RE[_0x2e6374(_0x223c40._0x50fd37)](_0x3d5ebc['slice'](0x0,_0x464265)[_0x2e6374(0x1af)]());}__name(isAssignmentLine,_0x26a9f7(0x19b));function isAssignmentOf(_0x48f48f,_0x2b59bb){const _0x52f22c=_0x26a9f7,_0x5cbd58=_0x48f48f[_0x52f22c(0x1af)]();if(_0x5cbd58===''||_0x5cbd58['startsWith']('#'))return![];const _0x3efa21=_0x5cbd58['indexOf']('=');if(_0x3efa21<=0x0)return![];return _0x5cbd58[_0x52f22c(0x1b0)](0x0,_0x3efa21)[_0x52f22c(0x1af)]()===_0x2b59bb;}__name(isAssignmentOf,_0x26a9f7(0x161));function splitLines(_0x58984f){const _0x527807={_0x3016c1:0x15c},_0x1f7c3f=_0x26a9f7,_0x33bb61=_0x58984f['endsWith']('\x0a'),_0x437983=_0x33bb61?_0x58984f[_0x1f7c3f(0x1b0)](0x0,-0x1):_0x58984f;return{'lines':_0x437983===''?[]:_0x437983[_0x1f7c3f(_0x527807._0x3016c1)]('\x0a'),'trailingNewline':_0x33bb61};}__name(splitLines,_0x26a9f7(0x1ca));function joinLines(_0x58d731,_0x44fa16){const _0x2e8af2=_0x58d731['join']('\x0a');return _0x44fa16||_0x2e8af2===''?_0x2e8af2+'\x0a':_0x2e8af2;}__name(joinLines,_0x26a9f7(0x149));function insertEnvVar(_0x565aa8,_0x286dde,_0x2afe6a,_0x3ca0ac){const _0x5bd8f1={_0x43aacb:0x1c8,_0x41357d:0x1a5,_0x1209bb:0x162,_0x297f4f:0x1d5},_0x27c644=_0x26a9f7,_0x39b334=_0x286dde+'='+serializeEnvValue(_0x2afe6a),{lines:_0xcca0b2,trailingNewline:_0x5f083e}=splitLines(_0x565aa8);if(_0x3ca0ac){const _0x2ca779=new RegExp('\x5cb'+_0x3ca0ac[_0x27c644(_0x5bd8f1._0x43aacb)]()+'\x5cb'),_0x538941=_0xcca0b2[_0x27c644(0x192)](_0x4d5adf=>isSectionDivider(_0x4d5adf)&&_0x2ca779[_0x27c644(0x18e)](_0x4d5adf[_0x27c644(0x1c8)]()));if(_0x538941!==-0x1){let _0x2bb90a=_0xcca0b2[_0x27c644(0x1a5)];for(let _0xb6d080=_0x538941+0x1;_0xb6d080<_0xcca0b2[_0x27c644(_0x5bd8f1._0x41357d)];_0xb6d080++){if(isSectionDivider(_0xcca0b2[_0xb6d080])){_0x2bb90a=_0xb6d080;break;}}let _0x26420a=-0x1,_0x440abf=-0x1;for(let _0x5141eb=_0x538941+0x1;_0x5141eb<_0x2bb90a;_0x5141eb++){if(_0xcca0b2[_0x5141eb]['trim']()!=='')_0x440abf=_0x5141eb;if(isAssignmentLine(_0xcca0b2[_0x5141eb]))_0x26420a=_0x5141eb;}const _0x3ecafc=_0x26420a>=0x0?_0x26420a:_0x440abf,_0x5d3894=_0x3ecafc>=0x0?_0x3ecafc+0x1:_0x538941+0x1;return _0xcca0b2[_0x27c644(0x157)](_0x5d3894,0x0,_0x39b334),joinLines(_0xcca0b2,_0x5f083e||_0xcca0b2['length']>0x0);}if(_0xcca0b2['length']>0x0)_0xcca0b2[_0x27c644(_0x5bd8f1._0x1209bb)]('');return _0xcca0b2['push'](_0x27c644(_0x5bd8f1._0x297f4f)+_0x3ca0ac+_0x27c644(0x138),_0x39b334),joinLines(_0xcca0b2,!![]);}return _0xcca0b2['push'](_0x39b334),joinLines(_0xcca0b2,!![]);}__name(insertEnvVar,_0x26a9f7(0x17a));function removeEnvVar(_0x5668ae,_0x31ccf5){const _0x43465a={_0x21c800:0x1da,_0x2dadce:0x1a5},_0x117c1e=_0x26a9f7,{lines:_0x4b68c4,trailingNewline:_0x3eda9b}=splitLines(_0x5668ae),_0x5670f7=_0x4b68c4[_0x117c1e(_0x43465a._0x21c800)](_0x3b1c35=>!isAssignmentOf(_0x3b1c35,_0x31ccf5)),_0x353c8e=_0x5670f7[_0x117c1e(_0x43465a._0x2dadce)]!==_0x4b68c4[_0x117c1e(_0x43465a._0x2dadce)];return{'content':joinLines(_0x5670f7,_0x3eda9b),'removed':_0x353c8e};}__name(removeEnvVar,_0x26a9f7(0x1a9));var SECTION_BY_KIND={'app':_0x26a9f7(0x19a),'runner':_0x26a9f7(0x14e),'secret':void 0x0};function planAddVariable(_0x2f8ee2){const _0x4c8abc={_0x23639b:0x183,_0x13e309:0x1bc,_0x5dcd7c:0x17b,_0x5643c0:0x177,_0x18e1d7:0x197,_0x388573:0x1ae,_0x1eb9ea:0x1db,_0x49ab77:0x142,_0x9cacc7:0x1dd},_0x34baa4=_0x26a9f7,{name:_0x563992,kind:_0x2ac0f2}=_0x2f8ee2;if(_0x2ac0f2===_0x34baa4(_0x4c8abc._0x23639b)){if(!isRunnerConfigKey(_0x563992))return{'ok':![],'code':'unknown-runner-key','message':_0x563992+_0x34baa4(_0x4c8abc._0x13e309)};}else{if(!isExternalVarName(_0x563992))return{'ok':![],'code':_0x34baa4(0x159),'message':_0x563992+'\x20must\x20be\x20UPPER_SNAKE\x20(e.g.\x20APP_BASE_URL)\x20so\x20a\x20scenario\x20can\x20reference\x20it\x20by\x20name.'};}const _0x13f19e=envKeys(_0x2f8ee2[_0x34baa4(0x196)])[_0x34baa4(_0x4c8abc._0x5dcd7c)](_0x563992),_0x177d13=envKeys(_0x2f8ee2[_0x34baa4(_0x4c8abc._0x5643c0)])['has'](_0x563992),_0x5c42d8=_0x2ac0f2===_0x34baa4(_0x4c8abc._0x18e1d7)?'secrets':_0x34baa4(0x180),_0x204622=_0x5c42d8==='secrets'?_0x177d13:_0x13f19e,_0x25a6e4=_0x5c42d8===_0x34baa4(_0x4c8abc._0x388573)?_0x34baa4(0x1bb):_0x34baa4(_0x4c8abc._0x1eb9ea);if(_0x204622)return{'ok':![],'code':_0x34baa4(_0x4c8abc._0x49ab77),'message':_0x563992+_0x34baa4(_0x4c8abc._0x9cacc7)+_0x25a6e4+'\x20—\x20pick\x20a\x20different\x20name\x20or\x20edit\x20the\x20existing\x20value.'};const _0x277ebf=[];return _0x2ac0f2===_0x34baa4(_0x4c8abc._0x18e1d7)&&_0x13f19e&&_0x277ebf[_0x34baa4(0x162)](_0x563992+_0x34baa4(0x144)),_0x2ac0f2!==_0x34baa4(_0x4c8abc._0x18e1d7)&&_0x177d13&&_0x277ebf[_0x34baa4(0x162)](_0x563992+'\x20is\x20also\x20set\x20in\x20unotest/.secrets\x20—\x20the\x20secret\x20value\x20shadows\x20this\x20one.'),{'ok':!![],'target':_0x5c42d8,'sectionLabel':SECTION_BY_KIND[_0x2ac0f2],'warnings':_0x277ebf};}__name(planAddVariable,_0x26a9f7(0x1c4));function deleteShadowWarning(_0x220b5a,_0x2874e0,_0x5ef179){const _0x2acd28={_0x1b728e:0x1b2},_0x28916f=_0x26a9f7;if(_0x5ef179!==void 0x0&&_0x5ef179!==_0x2874e0)return[_0x220b5a+_0x28916f(_0x2acd28._0x1b728e)];return[];}__name(deleteShadowWarning,_0x26a9f7(0x1a7));var TERMINAL_RUNTIME_STATES=[_0x26a9f7(0x165),_0x26a9f7(0x181),_0x26a9f7(0x184)];function isTerminalRuntimeState(_0x35ba46){return TERMINAL_RUNTIME_STATES['includes'](_0x35ba46);}__name(isTerminalRuntimeState,'isTerminalRuntimeState');export{BLOBS_DIR,COLLECTIONS_SUBDIR,COLLECTION_NAME_FORBIDDEN_RE,COMMANDS_FILE,DAY_INDEX_FILE,E2E_SUBDIR,ENV_FILE,EXPECT_FAIL_ANNOTATION,HEARTBEAT_FILE,HELPERS_SUBDIR,InvalidBlobHashError,LOCK_FILE,LOG_FILE,PICKER_SNAPSHOT_FILE,RUNNER_CONFIG_KEYS,RUNS_SUBDIR,RUNTIME_FILE,RUN_INDEX_SCHEMA_VERSION,RUN_MANIFEST_FILE,RUN_SOURCES_FILE,RunnerAdapterNotFoundError,RunnerNotConfiguredError,SCENARIOS_INDEX_DIR,SCENARIOS_LATEST_FILE,SCENARIO_RECENT_WINDOW,SECRETS_FILE,SEGMENT_NAME_FORBIDDEN_RE,SNAPSHOTS_SUBDIR,STDERR_FILE,STDOUT_FILE,STEPS_FILE,TERMINAL_RUNTIME_STATES,TERMINAL_WS_EVENT,UNOTEST_DIR,UnplaceableRunIdError,UnsupportedRunKindError,activeEnvName,blobPathFor,blobRelPathFor,blobRelSegmentsFor,blobsRootFor,categorizeVariable,debugDirFor,debuggerFileFor,deleteShadowWarning,envFileFor,envKeys,envLayerFilesFor,foldScenarioRun,insertEnvVar,isAnnotationLine,isExternalVarName,isFailingStatus,isRegexLiteral,isRunnerConfigKey,isTerminalRuntimeState,makeRunId,parseAppServerEvent,parseEnvContent,parseScenarioAnnotations,planAddVariable,projectRunDirFor,projectRunsRoot,regexLiteral,removeEnvVar,requireRunDirFor,runDirFor,runIdStartedAt,runsDirFor,sanitizeRunIdSegment,scenarioIndexFileName,scenarioRefFromFileName,secretsFileFor,secretsLayerFilesFor,serializeEnvValue,shardDaysDescending,shardDirFor,shardPathForRunId,shardPathForTimestamp,testDirFor,validateCollectionName,validateSegmentName};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@unotest/protocol",
3
- "version": "0.19.0",
3
+ "version": "0.20.0",
4
4
  "description": "Cross-runner protocol for the @unotest ecosystem: shared TypeScript types, path constants, the IRunnerAdapter contract that lets @unotest/viewer drive @unotest/web, @unotest/mobile (and future runners) through the same surface. Pure types + pure functions only — zero runtime deps, browser-safe.",
5
5
  "license": "MIT",
6
6
  "publishConfig": {