prestashopheaven / runtime-clock
The clock of a PrestaHaven module on psr/clock: the system clock, the local time of a shop (its PS_TIMEZONE) and a frozen clock for tests.
v1.0.0
2026-11-07 10:33 UTC
Requires
- php: >=8.1
- psr/clock: ^1.0
Requires (Dev)
None
Suggests
None
Provides
None
Conflicts
None
Replaces
None
This package is auto-updated.
Last update: 2026-11-07 22:36:12 UTC
README
The clock of a PrestaHaven module on psr/clock: the system clock, the local time of a shop (its PS_TIMEZONE) and a frozen clock for tests.
Use when
Code needs the current time or the local time of a shop (time windows, waiting times, expiry), and tests need a fixed time; type-hint Psr\Clock\ClockInterface in Application ports.
Install
composer require prestashopheaven/runtime-clock
Usage
Read-only split of prestashopheaven/mono-runtime-support: changes,
issues and pull requests go there. MIT License.