Fix test to check for sanitized string from alertnotify.

If client version is 1.1.0-rc1, the alertnotify message will have
been sanitized and will show as 1.1.0rc1.
This commit is contained in:
Simon 2018-04-04 21:55:20 -07:00
parent f6d09aa822
commit 6901d30830
1 changed files with 3 additions and 2 deletions

View File

@ -7,6 +7,7 @@
#include "init.h"
#include "ui_interface.h"
#include "util.h"
#include "utilstrencodings.h"
#include <boost/filesystem/operations.hpp>
#include <fstream>
@ -149,10 +150,10 @@ TEST_F(DeprecationTest, AlertNotify) {
EXPECT_EQ(r.size(), 1u);
// -alertnotify restricts the message to safe characters.
auto expectedMsg = strprintf(
auto expectedMsg = SanitizeString(strprintf(
"This version will be deprecated at block height %d, and will automatically shut down. You should upgrade to the latest version of Zcash. To disable deprecation for this version, set disabledeprecation to %s.",
DEPRECATION_HEIGHT,
CLIENT_VERSION_STR);
CLIENT_VERSION_STR));
// Windows built-in echo semantics are different than posixy shells. Quotes and
// whitespace are printed literally.