summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorChristian Weiske <cweiske@cweiske.de>2012-01-21 12:38:17 +0100
committerChristian Weiske <cweiske@cweiske.de>2012-01-21 12:38:17 +0100
commit814f99d4711816c346d2df3761c7c4d2f86cd775 (patch)
tree1ae4795e710821afa8d0087fe03437a53496e26d /tests
parentdf00540d4c2d5c03352d1e79e526ccd6f7cbcd9f (diff)
downloadsemanticscuttle-814f99d4711816c346d2df3761c7c4d2f86cd775.tar.gz
semanticscuttle-814f99d4711816c346d2df3761c7c4d2f86cd775.tar.bz2
Fix bug #3111254: getIdFromUser() always returns an integer now (part 2)
Diffstat (limited to 'tests')
-rw-r--r--tests/UserTest.php16
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/UserTest.php b/tests/UserTest.php
index 6cd6786..85d2204 100644
--- a/tests/UserTest.php
+++ b/tests/UserTest.php
@@ -246,6 +246,22 @@ class UserTest extends TestBase
);
}
+ public function testGetIdFromUserParamId()
+ {
+ $uid = $this->addUser();
+ $newId = $this->us->getIdFromUser($uid);
+ $this->assertInternalType('integer', $newId);
+ $this->assertEquals($uid, $newId);
+ }
+
+ public function testGetIdFromUserParamUsername()
+ {
+ $uid = $this->addUser('someusername');
+ $newId = $this->us->getIdFromUser('someusername');
+ $this->assertInternalType('integer', $newId);
+ $this->assertEquals($uid, $newId);
+ }
+
/**