Rob Crowe

    Rob Crowe

    1 month ago
    For policies that have a time based element to the condition, for example
    timestamp(P.attr.some_claim).timeSince() < duration("1h")
    . Is there a good way to make those policy tests deterministic?
    P.attr.some_claim
    is hardcoded RFC3339 in the test &
    timeSince()
    uses the current server time.
    Charith (Cerbos)

    Charith (Cerbos)

    1 month ago
    Unfortunately, no. Thanks for raising it though. It's certainly useful to be able to control the time during tests.
    Rob Crowe

    Rob Crowe

    1 month ago
    👍🏻 want me to add an issue?
    Charith (Cerbos)

    Charith (Cerbos)

    1 month ago
    Sure. Go ahead.
    Rob Crowe

    Rob Crowe

    1 month ago
    That was speedy @Charith (Cerbos) 🙂 🚀 Thanks
    Nice touch with global and local
    Charith (Cerbos)

    Charith (Cerbos)

    1 month ago
    Thanks for raising the issue. We'll try to get a new release out soon.
    Alex Olivier (Cerbos)

    Alex Olivier (Cerbos)

    1 month ago
    Rob Crowe

    Rob Crowe

    1 month ago
    As soon as I saw it in #announcements it went straight out to prod 😄
    thanks for coming back to me here, appreciated 🙇🏻