/** * format() should return string if format is html */ public function testFormat_returnsString_ifFormatIsText() { $bullet = new Bullet(); $expected = html_entity_decode('•'); $actual = $bullet->format('text'); $this->assertEquals($expected, $actual); return; }
* Cosa ricevo * * subject_id * lesson_id */ //function to order by date function cmp($a, $b) { if ($a->getDate() == $b->getDate()) { return 0; } return $a->getDate() < $b->getDate() ? -1 : 1; } //First thing I get all the snippets about the document // 1) get bullets $bullets = Bullet::getBulletsByLesson($_GET['lesson_id']); ?> <div class="lesson-header"> <h2 class="cut-text">Showing notes about lesson</h2> </div> <div class="add-note"> <?php echo '<a href="main.php?sidebar=lessons&subject_id=' . $_GET['subject_id'] . '&content=add&lesson_id=' . $_GET['lesson_id'] . '"<h2><i class="fa fa-pencil-square-o"></i> Edit lesson</h2></a>'; ?> </div> <br>
public function deleteBullet() { $id = Input::get('id'); Bullet::destroy($id); return $this->success(null, null); }
public function testToArray() { $this->assertTrue(is_array($this->bullet->toArray())); }
/** * Remove the specified resource from storage. * * @param int $id * @return Response */ public function destroy($id) { Bullet::destroy($id); return Redirect::route("projects.index"); }