Function When_I_set_system_time

  • When I set system time:

    When I set system time to {int}
    When I set system time to {string}

    Parameters

    • now: string | number

    Returns void

    Change current system time to Unix epoch:

    When I set system time to 0
    

    Change current system time to 2020-02-02:

    When I set system time to "2020-02-02"
    

    A preceding step "When I use fake timers" is required. For example:

    When I use fake timers
    And I set system time to "2020-02-02"