DataSift\Storyplayer\OutputTest::testCanLogCliWarning PHP Method

testCanLogCliWarning() public method

    public function testCanLogCliWarning()
    {
        // ----------------------------------------------------------------
        // setup the test
        $msg = "this might be an emergency, damnit!";
        $plugin1 = Mockery::mock("DataSift\\Storyplayer\\OutputLib\\OutputPlugin");
        $plugin1->shouldReceive('logCliWarning')->once()->with($msg);
        $plugin2 = Mockery::mock("DataSift\\Storyplayer\\OutputLib\\OutputPlugin");
        $plugin2->shouldReceive('logCliWarning')->once()->with($msg);
        $obj = new Output();
        $obj->usePluginInSlot($plugin1, "console");
        $obj->usePluginInSlot($plugin2, "slot1");
        // ----------------------------------------------------------------
        // perform the change
        $obj->logCliWarning($msg);
        // ----------------------------------------------------------------
        // test the results
        Mockery::close();
    }