testVarDump(); } public function testVarDump() { ob_start(); $cliOutput = new CliVarDumpOutput(function ($dumped) { echo $dumped; }); $cliOutput->print("Hello, world!"); $output = ob_get_clean(); $this->assertStringContains($output, 'string(13) "Hello, world!"'); } }