@RepeatedTest(2)
    @Transactional(transactionManager = "ticketTransactionManager", readOnly = false)
    void verifyCountSessionsPerUser() throws Throwable {
        val ticketGrantingTicketId = TestTicketIdentifiers.generate().ticketGrantingTicketId();
        assumeTrue(canTicketRegistryIterate());
        val id = UUID.randomUUID().toString();
        ticketRegistry.addTicket(new TicketGrantingTicketImpl(ticketGrantingTicketId,
            CoreAuthenticationTestUtils.getAuthentication(id),
            NeverExpiresExpirationPolicy.INSTANCE));
        val count = ticketRegistry.countSessionsFor(id);
        assertTrue(count > 0);
    }
This is {@link BaseTicketRegistryTests}.

@author Misagh Moayyed
@since 5.3.0
core/cas-server-core-tickets/src/test/java/org/apereo/cas/ticket/registry/BaseTicketRegistryTests.java