Both count: five years since the wedding, and living together throughout. Only the years you lived together count.