Record original-alignment implementation and traceability checkpoint

Capture current source, content data, tests, asset licenses, and original-specification traceability. Original implementation remains incomplete. The accepted matching UI generation passed 154 suites and 12,253 checks, with eight rendered staff-contract screens reviewed. Latest native Windows and full-original acceptance remain outstanding.
This commit is contained in:
Takeshi
2026-09-30 23:52:24 +09:00
parent 6077e02ebe
commit 5dde0c5ec2
490 changed files with 54051 additions and 809 deletions
+20 -17
View File
@@ -1,7 +1,7 @@
extends SceneTree
const FOURTEEN_DAYS_MINUTES := 14 * SimulationKernel.MINUTES_PER_DAY
const RUNTIME_SNAPSHOT_VERSION := 9
const RUNTIME_SNAPSHOT_VERSION := 13
var _checks := 0
var _failures := 0
@@ -39,7 +39,7 @@ func _new_fixture(seed: int, enable_operations := true) -> Dictionary:
int(initial_snapshot[&"systems"][&"runtime"].get(
&"runtime_schema_version", -1
)) == RUNTIME_SNAPSHOT_VERSION,
"fixture emits Runtime snapshot schema v9"
"fixture emits Runtime snapshot schema v10"
)
if enable_operations:
var enabled: Dictionary = runtime.enable_production_operations()
@@ -80,6 +80,9 @@ func _advance_operations_boundary_slice(fixture: Dictionary, amount: int) -> int
clock.absolute_minute = target
clock.call("_sync_calendar_fields")
clock.snapshot_version += step
# Weather belongs to TIME_BOUNDARIES even when AI is skipped.
runtime.call("_advance_weather", target)
runtime.call("_advance_facility_upkeep", target)
runtime.call("_advance_operations_time", target)
if bool(runtime.get_operations_report().get(&"runtime_failure_latched", false)):
break
@@ -283,17 +286,17 @@ func _test_full_partial_payroll_bankruptcy_and_v9_tamper() -> void:
_expect(bool(enabled.get(&"ok", false)), "payroll fixture enables Operations after the pre-opening hire")
var full_advanced := _advance_operations_boundary_slice(
fixture, SimulationKernel.MINUTES_PER_DAY
fixture, SimulationKernel.MINUTES_PER_DAY - 360
)
var full: Dictionary = runtime.staff_service.get_payroll_settlement(&"payroll-day-00000001")
_expect(
full_advanced == SimulationKernel.MINUTES_PER_DAY
full_advanced == SimulationKernel.MINUTES_PER_DAY - 360
and _operations_slice_is_healthy(fixture)
and clock.absolute_minute == SimulationKernel.MINUTES_PER_DAY + 6 * 60
and clock.absolute_minute == SimulationKernel.MINUTES_PER_DAY
and int(full.get(&"new_wages_total", -1)) == daily_wage
and int(full.get(&"paid_total", -1)) == daily_wage
and int(full.get(&"unpaid_after_total", -1)) == 0,
"Day 1 payroll is paid in full and closes at exactly 06:00"
"Day 1 payroll is paid in full and closes at exactly 00:00"
)
var cash_now: int = runtime.economy_service.get_balance(runtime.PLAYER_CASH_ACCOUNT)
@@ -318,7 +321,7 @@ func _test_full_partial_payroll_bankruptcy_and_v9_tamper() -> void:
_expect(
partial_advanced == SimulationKernel.MINUTES_PER_DAY
and _operations_slice_is_healthy(fixture)
and clock.absolute_minute == 2 * SimulationKernel.MINUTES_PER_DAY + 6 * 60
and clock.absolute_minute == 2 * SimulationKernel.MINUTES_PER_DAY
and int(partial.get(&"new_wages_total", -1)) == daily_wage
and int(partial.get(&"paid_total", -1)) == 50
and int(partial.get(&"unpaid_after_total", -1)) == daily_wage - 50,
@@ -326,24 +329,21 @@ func _test_full_partial_payroll_bankruptcy_and_v9_tamper() -> void:
)
var terminal_advanced := _advance_operations_boundary_slice(
fixture, 2 * SimulationKernel.MINUTES_PER_DAY
fixture, SimulationKernel.MINUTES_PER_DAY
)
var coordinator: OperationsCoordinator = runtime.operations_coordinator
var last_three_negative := true
for day in [2, 3, 4]:
for day in [1, 2, 3]:
var summary: Dictionary = coordinator.get_day_summary(day)
last_three_negative = last_three_negative \
and int(summary.get(&"net_profit", 0)) < 0 \
and int((summary.get(&"settlement", {}) as Dictionary).get(
&"arrears_total", 0
)) > 0
and int(summary.get(&"net_profit", 0)) < 0
_expect(
terminal_advanced == 2 * SimulationKernel.MINUTES_PER_DAY
and clock.absolute_minute == 4 * SimulationKernel.MINUTES_PER_DAY + 6 * 60
terminal_advanced == SimulationKernel.MINUTES_PER_DAY
and clock.absolute_minute == 3 * SimulationKernel.MINUTES_PER_DAY
and last_three_negative
and coordinator.get_consecutive_insolvency_count() == 3
and coordinator.get_terminal_state() == &"BANKRUPT",
"three consecutive negative closes with arrears enter BANKRUPT at the third boundary"
"three consecutive negative closes, including the fully paid first day, enter BANKRUPT at the third boundary"
)
var terminal_snapshot: Dictionary = runtime.create_snapshot()
var terminal_digest := SimulationDigest.compute(terminal_snapshot)
@@ -353,7 +353,7 @@ func _test_full_partial_payroll_bankruptcy_and_v9_tamper() -> void:
)
clock.advance_minutes(180)
_expect(
clock.absolute_minute == 4 * SimulationKernel.MINUTES_PER_DAY + 6 * 60
clock.absolute_minute == 3 * SimulationKernel.MINUTES_PER_DAY
and SimulationDigest.compute(runtime.create_snapshot()) == terminal_digest,
"BANKRUPT is terminal: later time requests are exact no-ops"
)
@@ -362,6 +362,9 @@ func _test_full_partial_payroll_bankruptcy_and_v9_tamper() -> void:
"BANKRUPT cannot be acknowledged away"
)
var blocked_command: CommandResult = runtime.submit_command(&"change_resources", {&"deltas": {&"gold": 500}})
_expect(not blocked_command.is_success() and SimulationDigest.compute(runtime.create_snapshot()) == terminal_digest, "terminal rejects new commands without changing funds, command IDs, or history")
_assert_v9_tamper_rejected(
runtime,
terminal_snapshot,