<?php

/**
 * Created by PhpStorm.
 * User: stanley-king
 * Date: 16/8/31
 * Time: 下午4:56
 */


function callback($buffer)
{
    return 'hello world';
}

class TestObfun extends PHPUnit_Framework_TestCase
{
    private function work()
    {
        echo "1 2 3 4 5 6";
    }
    private function otherStart()
    {
        ob_start();
        $this->work();
        ob_end_clean();
    }
    public function testObstart()
    {
        ob_start();
        $this->work();
        $this->otherStart();
        ob_end_flush();
        $content = ob_get_contents();
        ob_clean();
    }

}
