summaryrefslogtreecommitdiff
path: root/tests/iid.cpp
diff options
context:
space:
mode:
authorlouiz’ <louiz@louiz.org>2016-12-11 16:34:38 +0100
committerlouiz’ <louiz@louiz.org>2016-12-11 16:34:38 +0100
commitf653906f9de8cbcecf5717e18c696d1029fc2c8f (patch)
tree0ad6e57692b4728ff744650b3ba238cf35c52209 /tests/iid.cpp
parent36252ad217ee0c8846cafce8fa35c2e776e39605 (diff)
downloadbiboumi-f653906f9de8cbcecf5717e18c696d1029fc2c8f.tar.gz
biboumi-f653906f9de8cbcecf5717e18c696d1029fc2c8f.tar.bz2
biboumi-f653906f9de8cbcecf5717e18c696d1029fc2c8f.tar.xz
biboumi-f653906f9de8cbcecf5717e18c696d1029fc2c8f.zip
Add a None type for the Iid class (when the iid is completely empty)
Diffstat (limited to 'tests/iid.cpp')
-rw-r--r--tests/iid.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/iid.cpp b/tests/iid.cpp
index b42b9e5..3da0396 100644
--- a/tests/iid.cpp
+++ b/tests/iid.cpp
@@ -83,6 +83,12 @@ TEST_CASE("Iid creation")
CHECK(iid6.get_local() == "##channel");
CHECK(iid6.get_server() == "");
CHECK(iid6.type == Iid::Type::Channel);
+
+ Iid iid7("", chantypes);
+ CHECK(std::to_string(iid7) == "");
+ CHECK(iid7.get_local() == "");
+ CHECK(iid7.get_server() == "");
+ CHECK(iid7.type == Iid::Type::None);
}
TEST_CASE("Iid creation in fixed_server mode")