topic_data: Rename topic_data module to stream_topic_history.

`stream_topic_history` is a more appropriate name as this
module will contain information about last message of a
stream in upcoming commits. Function and variable names
are changed accordingly like:

* topic_history() -> per_stream_history()
* get_recent_names() -> get_recent_topic_names()
* name -> topic_name
This commit is contained in:
Hashir Sarwar
2020-03-22 22:40:05 +05:00
committed by Tim Abbott
parent c5eddcb1ca
commit ee0d4541b4
28 changed files with 138 additions and 136 deletions

View File

@@ -98,7 +98,7 @@ alert_words.process_message = noop;
// We can also bring in real code:
zrequire('recent_senders');
zrequire('unread');
zrequire('topic_data');
zrequire('stream_topic_history');
// And finally require the module that we will test directly:
zrequire('message_store');
@@ -118,7 +118,7 @@ run_test('message_store', () => {
assert.equal(message, in_message);
// There are more side effects.
const topic_names = topic_data.get_recent_names(denmark_stream.stream_id);
const topic_names = stream_topic_history.get_recent_topic_names(denmark_stream.stream_id);
assert.deepEqual(topic_names, ['copenhagen']);
});