@Test public void testUnexpectedCookieValuesCountThrowsException() throws Exception { thrown.expect(Exception.class); String formattedCookie = SessionCookie.formatCookie(new String[] { "singleValueCookie" }); createUserCookie(formattedCookie); }
@Test public void testCorruptedAcquisitionDateValueThrowsExceptionOnCookieParsing() throws Exception { thrown.expect(Exception.class); String formattedCookie = UserCookie.formatCookie(new String[] { userId, "corruptedAcquisitionTime" }); createUserCookie(formattedCookie); }