Subversion-Projekte lars-tiefland.php_share

Revision

Details | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
1 lars 1
<?php
2
/**
3
 * Unit test class for the FirebugConsole sniff.
4
 *
5
 * PHP version 5
6
 *
7
 * @category  PHP
8
 * @package   PHP_CodeSniffer_MySource
9
 * @author    Greg Sherwood <gsherwood@squiz.net>
10
 * @copyright 2006 Squiz Pty Ltd (ABN 77 084 670 600)
11
 * @license   http://matrix.squiz.net/developer/tools/php_cs/licence BSD Licence
12
 * @version   CVS: $Id: FirebugConsoleUnitTest.php 253189 2008-02-19 03:35:31Z squiz $
13
 * @link      http://pear.php.net/package/PHP_CodeSniffer
14
 */
15
 
16
/**
17
 * Unit test class for the FirebugConsole sniff.
18
 *
19
 * A sniff unit test checks a .inc file for expected violations of a single
20
 * coding standard. Expected errors and warnings are stored in this class.
21
 *
22
 * @category  PHP
23
 * @package   PHP_CodeSniffer_MySource
24
 * @author    Greg Sherwood <gsherwood@squiz.net>
25
 * @copyright 2006 Squiz Pty Ltd (ABN 77 084 670 600)
26
 * @license   http://matrix.squiz.net/developer/tools/php_cs/licence BSD Licence
27
 * @version   Release: 1.2.1
28
 * @link      http://pear.php.net/package/PHP_CodeSniffer
29
 */
30
class MySource_Tests_Debug_FirebugConsoleUnitTest extends AbstractSniffUnitTest
31
{
32
 
33
 
34
    /**
35
     * Returns the lines where errors should occur.
36
     *
37
     * The key of the array should represent the line number and the value
38
     * should represent the number of errors that should occur on that line.
39
     *
40
     * @param string $testFile The name of the file being tested.
41
     *
42
     * @return array(int => int)
43
     */
44
    public function getErrorList($testFile='FirebugConsoleUnitTest.js')
45
    {
46
        if ($testFile !== 'FirebugConsoleUnitTest.js') {
47
            return array();
48
        }
49
 
50
        return array(
51
                1 => 1,
52
                2 => 1,
53
                3 => 1,
54
                5 => 1,
55
                6 => 1,
56
                8 => 1,
57
               );
58
 
59
    }//end getErrorList()
60
 
61
 
62
    /**
63
     * Returns the lines where warnings should occur.
64
     *
65
     * The key of the array should represent the line number and the value
66
     * should represent the number of warnings that should occur on that line.
67
     *
68
     * @return array(int => int)
69
     */
70
    public function getWarningList()
71
    {
72
        return array();
73
 
74
    }//end getWarningList()
75
 
76
 
77
}//end class
78
 
79
?>