Admin_Apple_Notice_Test::testFormattingSingle PHP Метод

testFormattingSingle() публичный Метод

    public function testFormattingSingle()
    {
        Admin_Apple_Notice::info('One error occurred: error 1', $this->user_id);
        ob_start();
        Admin_Apple_Notice::show();
        $notice = ob_get_contents();
        ob_end_clean();
        $expected = preg_replace('/\\s+/', '', '<div class="notice updated is-dismissible"><p><strong>One error occurred: error 1</strong></p></div>');
        $notice = preg_replace('/\\s+/', '', $notice);
        $this->assertEquals($expected, $notice);
    }