summaryrefslogtreecommitdiffstats
path: root/tests/lib/session
diff options
context:
space:
mode:
authorRobin Appelman <icewind@owncloud.com>2013-05-28 16:52:40 +0200
committerRobin Appelman <icewind@owncloud.com>2013-05-28 16:52:40 +0200
commit57f712f8a9e638157f1f7ce8158791834a365ee5 (patch)
treecb3eed810e42c6d82487ec25ef414fef7c60df05 /tests/lib/session
parentcc0cf931365d0c515038015bc7792f8500fafcc3 (diff)
downloadnextcloud-server-57f712f8a9e638157f1f7ce8158791834a365ee5.tar.gz
nextcloud-server-57f712f8a9e638157f1f7ce8158791834a365ee5.zip
implement ArrayInterface with Session
Diffstat (limited to 'tests/lib/session')
-rw-r--r--tests/lib/session/session.php9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/lib/session/session.php b/tests/lib/session/session.php
index be28251608a..72dee44e7cb 100644
--- a/tests/lib/session/session.php
+++ b/tests/lib/session/session.php
@@ -52,4 +52,13 @@ abstract class Session extends \PHPUnit_Framework_TestCase {
$this->instance->clear();
$this->assertFalse($this->instance->exists('foo'));
}
+
+ public function testArrayInterface() {
+ $this->assertFalse(isset($this->instance['foo']));
+ $this->instance['foo'] = 'bar';
+ $this->assertTrue(isset($this->instance['foo']));
+ $this->assertEquals('bar', $this->instance['foo']);
+ unset($this->instance['foo']);
+ $this->assertFalse(isset($this->instance['foo']));
+ }
}