[cpp-sp] branch main updated: Extend unit test.

Scott Cantor cantor.2 at osu.edu
Wed Jun 4 19:59:41 UTC 2025


This is an automated email from the git hooks/post-receive script.

scantor pushed a commit to branch main
in repository cpp-sp.

View the commit online:
http://git.shibboleth.net/view/?p=cpp-sp.git;a=commit;h=898f388eda5c76ded98ce7ee66ec2f552c8125c6

The following commit(s) were added to refs/heads/main by this push:
     new 898f388e Extend unit test.
898f388e is described below

commit 898f388eda5c76ded98ce7ee66ec2f552c8125c6
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Wed Jun 4 15:59:38 2025 -0400

    Extend unit test.
---
 tests/session/impl/MemorySessionCacheTests.cpp | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/tests/session/impl/MemorySessionCacheTests.cpp b/tests/session/impl/MemorySessionCacheTests.cpp
index 4217b5e2..5a1fe558 100644
--- a/tests/session/impl/MemorySessionCacheTests.cpp
+++ b/tests/session/impl/MemorySessionCacheTests.cpp
@@ -139,6 +139,21 @@ BOOST_FIXTURE_TEST_CASE(MemorySessionCache_tests, MemoryFixture)
 
     unique_lock<Session> session = cache->find(request, true, false);
     BOOST_CHECK(session);
+    if (session) {
+        session.unlock();
+    }
+
+    // Clear old response headers.
+    request.m_responseHeaders.clear();
+
+    cache->remove(request);
+
+    header = cookieName;
+    header += "=; max-age=0; path=/; secure=1; HttpOnly=1; SameSite=None";
+    BOOST_CHECK_EQUAL(request.m_responseHeaders["Set-Cookie"], header);
+    
+    session = cache->find("custom", key.c_str());
+    BOOST_CHECK(!session);
 }
 
 }

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the commits mailing list