from ._ClockStub import ClockStub
from ._SpyCall import SpyCall


class ClockSpy(ClockStub):
    def __init__(self, now=None, utc_now=None):
        super(ClockSpy, self).__init__(now, utc_now)
        self.now_call = SpyCall()
        self.utc_now_call = SpyCall()

    def now(self):
        self.now_call.register()
        return super().now()

    def utc_now(self):
        self.utc_now_call.register()
        return super().utc_now()
