1<?php 2class Mockable 3{ 4 public $constructorCalled = false; 5 public $cloned = false; 6 7 public function __construct() 8 { 9 $this->constructorCalled = false; 10 } 11 12 public function foo() 13 { 14 return true; 15 } 16 17 public function bar() 18 { 19 return true; 20 } 21 22 public function __clone() 23 { 24 $this->cloned = true; 25 } 26} 27