This change adds an initial set of unit tests for sessions: * reference counting and release * timeout calculation