diff options
author | Remko Tronçon <git@el-tramo.be> | 2011-07-12 18:47:03 (GMT) |
---|---|---|
committer | Remko Tronçon <git@el-tramo.be> | 2011-07-12 18:47:03 (GMT) |
commit | 63b311c1bb60469eb5e2ccd2107739e11b189a15 (patch) | |
tree | 870057043f88e91b71b961a821a4dace859fc839 /Swiften/JID/UnitTest | |
parent | c6819a5fd632d03cfe72a58922054765c7383aa6 (diff) | |
parent | 08536b4ed31c30a25a343c3c2619676e67a0c692 (diff) | |
download | swift-contrib-63b311c1bb60469eb5e2ccd2107739e11b189a15.zip swift-contrib-63b311c1bb60469eb5e2ccd2107739e11b189a15.tar.bz2 |
Merge branch 'swift-1.x'
* swift-1.x:
Fixed bug with illegal resource in JID resulting in empty resource.
Updated the german translation
Conflicts:
Swiften/IDN/StringPrep.cpp
Swiften/SASL/SCRAMSHA1ClientAuthenticator.cpp
Diffstat (limited to 'Swiften/JID/UnitTest')
-rw-r--r-- | Swiften/JID/UnitTest/JIDTest.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/Swiften/JID/UnitTest/JIDTest.cpp b/Swiften/JID/UnitTest/JIDTest.cpp index 6f7895a..cd21d03 100644 --- a/Swiften/JID/UnitTest/JIDTest.cpp +++ b/Swiften/JID/UnitTest/JIDTest.cpp @@ -23,6 +23,7 @@ class JIDTest : public CppUnit::TestFixture CPPUNIT_TEST(testConstructorWithString_UpperCaseDomain); CPPUNIT_TEST(testConstructorWithString_UpperCaseResource); CPPUNIT_TEST(testConstructorWithString_EmptyNode); + CPPUNIT_TEST(testConstructorWithString_IllegalResource); CPPUNIT_TEST(testConstructorWithStrings); CPPUNIT_TEST(testIsBare); CPPUNIT_TEST(testIsBare_NotBare); @@ -129,6 +130,12 @@ class JIDTest : public CppUnit::TestFixture CPPUNIT_ASSERT(!testling.isValid()); } + void testConstructorWithString_IllegalResource() { + JID testling("foo@bar.com/\xd8\xb1\xd9\x85\xd9\x82\xd9\x87\x20\xd8\xaa\xd8\xb1\xd9\x86\xd8\xb3\x20"); + + CPPUNIT_ASSERT(!testling.isValid()); + } + void testConstructorWithStrings() { JID testling("foo", "bar", "baz"); |