Fixed spacing in actions/cache/filebackend/filerepo/job folder
[mediawiki.git] / tests / selenium / SeleniumTestHTMLLogger.php
blob21332cf000c39a5d6298a6fa6c5198031f1064c1
1 <?php
3 class SeleniumTestHTMLLogger {
4 public function setHeaders() {
5 global $wgOut;
6 $wgOut->addHeadItem( 'selenium', '<style type="text/css">
7 .selenium pre {
8 overflow-x: auto; /* Use horizontal scroller if needed; for Firefox 2, not needed in Firefox 3 */
9 white-space: pre-wrap; /* css-3 */
10 white-space: -moz-pre-wrap !important; /* Mozilla, since 1999 */
11 white-space: -pre-wrap; /* Opera 4-6 */
12 white-space: -o-pre-wrap; /* Opera 7 */
13 /* width: 99%; */
14 word-wrap: break-word; /* Internet Explorer 5.5+ */
16 .selenium-success { color: green }
17 </style>' );
20 public function write( $message, $mode = false ) {
21 global $wgOut;
22 $out = '';
23 if ( $mode == SeleniumTestSuite::RESULT_OK ) {
24 $out .= '<span class="selenium-success">';
26 $out .= htmlspecialchars( $message );
27 if ( $mode == SeleniumTestSuite::RESULT_OK ) {
28 $out .= '</span>';
30 if ( $mode != SeleniumTestSuite::CONTINUE_LINE ) {
31 $out .= '<br />';
34 $wgOut->addHTML( $out );