diff tests/cmd-server-cmode/main.cpp @ 488:7e273b7f4f92

Irccd: new coding style, closes #576
author David Demelier <markand@malikania.fr>
date Tue, 26 Sep 2017 17:18:47 +0200
parents c6fbb6e0e06d
children f1ad428208d3
line wrap: on
line diff
--- a/tests/cmd-server-cmode/main.cpp	Fri Aug 11 13:45:42 2017 +0200
+++ b/tests/cmd-server-cmode/main.cpp	Tue Sep 26 17:18:47 2017 +0200
@@ -21,12 +21,11 @@
 #include <server-tester.hpp>
 
 using namespace irccd;
-using namespace irccd::command;
 
 namespace {
 
-std::string channel;
-std::string mode;
+std::string cmd_channel;
+std::string cmd_mode;
 
 } // !namespace
 
@@ -34,15 +33,15 @@
 public:
     void cmode(std::string channel, std::string mode)
     {
-        ::channel = channel;
-        ::mode = mode;
+        ::cmd_channel = channel;
+        ::cmd_mode = mode;
     }
 };
 
 class ServerChannelModeCommandTest : public CommandTester {
 public:
     ServerChannelModeCommandTest()
-        : CommandTester(std::make_unique<ServerChannelModeCommand>(),
+        : CommandTester(std::make_unique<server_channel_mode_command>(),
                         std::make_unique<ServerChannelModeTest>())
     {
         m_irccdctl.client().request({
@@ -58,11 +57,11 @@
 {
     try {
         poll([&] () {
-            return !channel.empty() && !mode.empty();
+            return !cmd_channel.empty() && !cmd_mode.empty();
         });
 
-        ASSERT_EQ("#staff", channel);
-        ASSERT_EQ("+c", mode);
+        ASSERT_EQ("#staff", cmd_channel);
+        ASSERT_EQ("+c", cmd_mode);
     } catch (const std::exception &ex) {
         FAIL() << ex.what();
     }