TestClock
A test clock enables deterministic control over objects in testmode. With a test clock, you can create objects at a frozen time in the past or future, and advance to a specific future time to observe webhooks and state changes. After the clock advances, you can either validate the current state of your scenario (and test your assumptions), change the current state of your scenario (and test more complex scenarios), or keep advancing forward in time.
Summary
Types
@type t() :: %Stripe.Resources.TestHelpers.TestClock{ created: integer(), deletes_after: integer(), frozen_time: integer(), id: String.t(), livemode: boolean(), name: String.t(), object: String.t(), status: String.t(), status_details: Stripe.Resources.TestHelpers.TestClock.StatusDetails.t() }
created- Time at which the object was created. Measured in seconds since the Unix epoch. Format: Unix timestamp.deletes_after- Time at which this clock is scheduled to auto delete. Format: Unix timestamp.frozen_time- Time at which all objects belonging to this clock are frozen. Format: Unix timestamp.id- Unique identifier for the object. Max length: 5000.livemode- Has the valuetrueif the object exists in live mode or the valuefalseif the object exists in test mode.name- The custom name supplied at creation. Max length: 5000. Nullable.object- String representing the object's type. Objects of the same type share the same value. Possible values:test_helpers.test_clock.status- The status of the Test Clock. Possible values:advancing,internal_failure,ready.status_details- Expandable.