This run_test helper sets up a convention that allows
us to give really short tracebacks for errors, and
eventually we can have more control over running
individual tests. (The latter goal has some
complications, since we often intentionally leak
setup in tests.)
This is a pretty pure code move, where we moved stuff from
message_store to pm_conversations:
insert_recent_private_message() -> recent.insert()
recent_private_messages -> recent.get()
The object message_store.recent_private_messages was not
encapsulated in a function before this change. Now it is
hidden in the scope of pm_conversations.recent.
Both of the modules touched here maintain 100% line coverage.
In pm_conversations.js, added function to make a user a PM partner and
another function to check if a user is a PM partner. A PM partner is
someone with whom the user has been in a PM with.