public function testSaveLoadDelete() { // Save it $this->obj['blog-slug-1']['title'] = 'My First Blog'; $this->obj['blog-slug-1']['content'] = 'Can I be in the blog-o-club too?'; $this->obj['blog-slug-2']['title'] = 'My Second Blog, and maybe the last'; $this->obj['blog-slug-2']['content'] = 'I promise to write something soon!'; $this->assertTrue($this->obj->save(), $this->obj->lastError()); // Grab some konown values to test with $colTitleValue = $this->obj['blog-slug-1']['title']; $colTitleValue2 = $this->obj['blog-slug-2']['title']; // Re-Load, check saved data $this->obj = NULL; $this->obj = new TestCFSuper(); $this->assertTrue($this->obj->load($this->_keyID), $this->obj->lastError()); // Test at least 2 supercolumns to make sure population is ok $this->assertTrue($colTitleValue == $this->obj['blog-slug-1']['title']); $this->assertTrue($colTitleValue2 == $this->obj['blog-slug-2']['title']); // Delete columnfamily $this->obj->delete(); $this->assertTrue($this->obj->save(), $this->obj->lastError()); // Confirm we can't load the key any more $this->obj = NULL; $this->obj = new TestCFSuper(); $this->assertFalse($this->obj->load($this->_keyID), $this->obj->lastError()); }