Menu

[r6]: / testing / auto-testing.php  Maximize  Restore  History

Download this file

49 lines (36 with data), 1.2 kB

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
<?php
require('css_results.php');
require('../css_parser.php');
ini_set('display_errors','On');
$css = new csstidy();
$css_code = file_get_contents('fisubsilver.css');
$css->parse($css_code);
if($css->css === $xhtml_result) {
echo '<div style="color:green">XHTML OK!</div>';
} else {
echo '<div style="color:red">XHTML failed!</div>';
}
$css_code = file_get_contents('base.css');
$css->parse($css_code);
if($css->css === $ala_result) {
echo '<div style="color:green">ALA OK!</div>';
} else {
echo '<div style="color:red">ALA failed!</div>';
}
$css_code = file_get_contents('base.css');
$css->set_cfg('optimise_shorthands',false);
$css->set_cfg('only_safe_optimisations',false);
$css->set_cfg('save_comments',true);
$css->set_cfg('merge_selectors',1);
$css->parse($css_code);
if($css->css === $ala_options_result) {
echo '<div style="color:green">ALA +options OK!</div>';
} else {
echo '<div style="color:red">ALA +options failed!</div>';
}
if($css->comments === $ala_options_comments) {
echo '<div style="color:green">ALA comments OK!</div>';
} else {
echo '<div style="color:red">ALA comments failed!</div>';
}
?>
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.