Package org.jasig.portal.events

Examples of org.jasig.portal.events.LoginEvent


            protected void callWithoutResult() {
                DateTime timeStamp = null;
                for (int i = 0; i <= 100; i++) {
                    String sessionId = UUID.randomUUID().toString().replaceAll("[\\s\\-()]", "").substring(0, EVENT_SESSION_LENGTH - 1);
                    sessionId = sessionId.substring(0, 10) + "_" + sessionId.substring(EVENT_SESSION_HYPHEN_LENGTH, sessionId.length());
                    LoginEvent loginEvent = TestEventFactory.newLoginEvent(this, "testServer", sessionId, person,
                            ImmutableSet.<String>of("local.0", "local.1"),
                            Collections.<String, List<String>>emptyMap());
                    final EventSession eventSession = eventSessionDao.getEventSession(loginEvent);
                    assertNotNull(eventSession);
                    assertEquals(sessionId, eventSession.getEventSessionId());
                    final Set<AggregatedGroupMapping> groupMappings = eventSession.getGroupMappings();
                    assertEquals(2, groupMappings.size());
                    timeStamp = loginEvent.getTimestampAsDate();
                }
                eventSessionDao.purgeEventSessionsBefore(timeStamp.plusYears(1));
            }
        });
View Full Code Here

TOP

Related Classes of org.jasig.portal.events.LoginEvent

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.