diff options
author | kondou <kondou@ts.unde.re> | 2013-09-09 16:57:46 +0200 |
---|---|---|
committer | kondou <kondou@ts.unde.re> | 2013-09-09 16:57:46 +0200 |
commit | 1832eb88726dce70d4f8a0a45bd574b0b688ab26 (patch) | |
tree | ce7c5b7a0e8a3e61f8bb93312cb7fedb6a4a58a7 /tests | |
parent | d18a070a0393ac3846053bcef1833dd01856e117 (diff) | |
download | nextcloud-server-1832eb88726dce70d4f8a0a45bd574b0b688ab26.tar.gz nextcloud-server-1832eb88726dce70d4f8a0a45bd574b0b688ab26.zip |
Pass view in \OC_Avatar to constructor and use $_ for enable_avatars
Diffstat (limited to 'tests')
-rw-r--r-- | tests/lib/avatar.php | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/lib/avatar.php b/tests/lib/avatar.php index 027e88d726d..1c5195f8eb1 100644 --- a/tests/lib/avatar.php +++ b/tests/lib/avatar.php @@ -11,16 +11,16 @@ class Test_Avatar extends PHPUnit_Framework_TestCase { public function testAvatar() { $this->markTestSkipped("Setting custom avatars with encryption doesn't work yet"); - $avatar = new \OC_Avatar(); + $avatar = new \OC_Avatar(\OC_User::getUser()); - $this->assertEquals(false, $avatar->get(\OC_User::getUser())); + $this->assertEquals(false, $avatar->get()); $expected = new OC_Image(\OC::$SERVERROOT.'/tests/data/testavatar.png'); - $avatar->set(\OC_User::getUser(), $expected->data()); + $avatar->set($expected->data()); $expected->resize(64); - $this->assertEquals($expected->data(), $avatar->get(\OC_User::getUser())->data()); + $this->assertEquals($expected->data(), $avatar->get()->data()); - $avatar->remove(\OC_User::getUser()); - $this->assertEquals(false, $avatar->get(\OC_User::getUser())); + $avatar->remove(); + $this->assertEquals(false, $avatar->get()); } } |