MDL-66694 mod_forum: Fix unit test
authorJun Pataleta <jun@moodle.com>
Thu, 17 Oct 2019 14:39:36 +0000 (22:39 +0800)
committerJun Pataleta <jun@moodle.com>
Thu, 17 Oct 2019 14:39:36 +0000 (22:39 +0800)
commit10cc5e8100d7bf68ae440d00f392a1d6bddfcf36
treecf7b02f03413a5f11febae6f8a564d155b6b229b
parent97aeba56ba6259ac883d792bf2bfaaaa2ffd8027
MDL-66694 mod_forum: Fix unit test

* Set $forum1's displaywordcount to true in
  test_mod_forum_get_discussion_posts() so that the word and char counts
  will be returned.
* Use count_words() and count_letters() instead of hard coding the
  expected values for the word and char counts.
mod/forum/tests/externallib_test.php