Source identity
| Field | Recorded value |
|---|---|
| Source type | GitHub source |
| Original record | Janady13/AI_Brain / tests/test_bulk_update.py |
| Date | Not specified in source |
| Repository | Janady13/AI_Brain |
| Revision | 50285aff347685f043e7a72e4d72891eebaa6cd6 |
| Branch | codex/build-online-github-ani-hrtsoc |
| Path or archive member | tests/test_bulk_update.py |
| Original SHA-256 | 714ddcd46b8b9fe3d35269aa5e78348025cf923bc0a5915f00f02cbd23df377d |
| Git blob SHA | 4f169c1acdd3484ea56ee43be668dbe13c32d5c9 |
| Reading-copy SHA-256 | 714ddcd46b8b9fe3d35269aa5e78348025cf923bc0a5915f00f02cbd23df377d |
Every recorded occurrence
These 7 records contain identical original source bytes. Their paths and revisions remain part of the archive.
| Original record | Branch or archive | Revision / identifier | Original location |
|---|---|---|---|
| Janady13/AI_Brain / tests/test_bulk_update.py | codex/build-online-github-ani-hrtsoc | 50285aff347685f043e7a72e4d72891eebaa6cd6 | Open original |
| Janady13/AI_Brain / tests/test_bulk_update.py | codex/build-online-github-ani-7v4kug | 5cd0bbf744b0aee9445913337e852889d9a8098e | Open original |
| Janady13/AI_Brain / tests/test_bulk_update.py | copilot/vscode1760283895982 | 9e1c1a5b171addb5bb4a83b2ea7dede50c1cc81e | Open original |
| Janady13/AI_Brain / tests/test_bulk_update.py | feature/seeder-engine-tests | cdb497ece2d1a770ca8c83eb1de8923cfaa9eceb | Open original |
| Janady13/AI_Brain / tests/test_bulk_update.py | codex/build-online-github-ani-7v4kug | 5cd0bbf744b0aee9445913337e852889d9a8098e | Open original |
| Janady13/AI_Brain / tests/test_bulk_update.py | copilot/vscode1760283895982 | 9e1c1a5b171addb5bb4a83b2ea7dede50c1cc81e | Open original |
| Janady13/AI_Brain / tests/test_bulk_update.py | codex/build-online-github-ani-hrtsoc | 50285aff347685f043e7a72e4d72891eebaa6cd6 | Open original |
Recovered source transcript
Download complete source text ↓45 lines · 1.6 KB
from scripts.bulk_update import BulkUpdatePlan, execute_bulk_updates, main
def test_execute_bulk_updates_dry_run_returns_projection():
plan = execute_bulk_updates(iterations=10, batch_size=5, limit=1, dry_run=True)
assert isinstance(plan, BulkUpdatePlan)
assert plan.dry_run is True
assert plan.executed_iterations == 5 # min(5, iterations)
assert plan.iterations == 10
assert plan.sample_runtime_seconds >= 0
assert plan.estimated_total_runtime_seconds >= plan.sample_runtime_seconds
def test_execute_bulk_updates_validates_arguments():
try:
execute_bulk_updates(iterations=0)
except ValueError as exc:
assert "iterations" in str(exc)
else: # pragma: no cover - ensure the exception is raised
raise AssertionError("Expected ValueError for iterations")
try:
execute_bulk_updates(iterations=1, batch_size=0)
except ValueError as exc:
assert "batch_size" in str(exc)
else: # pragma: no cover - ensure the exception is raised
raise AssertionError("Expected ValueError for batch_size")
try:
execute_bulk_updates(iterations=1, limit=0)
except ValueError as exc:
assert "limit" in str(exc)
else: # pragma: no cover - ensure the exception is raised
raise AssertionError("Expected ValueError for limit")
def test_bulk_update_main_outputs_json(capsys):
exit_code = main(["--iterations", "2", "--batch-size", "1", "--limit", "1"])
captured = capsys.readouterr()
assert exit_code == 0
assert "\"iterations\": 2" in captured.out
assert "dry_run" in captured.out