MediaWiki REL1_34
SpamBlacklistTest Class Reference

@group SpamBlacklist @group Database @covers SpamBlacklist More...

Inheritance diagram for SpamBlacklistTest:
Collaboration diagram for SpamBlacklistTest:

Public Member Functions

 spamProvider ()
 
 testSpam ( $links, $expected)
 @dataProvider spamProvider
 

Protected Member Functions

 setUp ()
 
 tearDown ()
 

Protected Attributes

array $blacklist = [ '\b01bags\.com\b', 'sytes\.net' ]
 Spam blacklist regexes.
 
SpamBlacklist $spamFilter
 
array $whitelist = [ 'a5b\.sytes\.net' ]
 Spam whitelist regexes.
 

Detailed Description

@group SpamBlacklist @group Database @covers SpamBlacklist

Definition at line 8 of file SpamBlacklistTest.php.

Member Function Documentation

◆ setUp()

SpamBlacklistTest::setUp ( )
protected

Definition at line 68 of file SpamBlacklistTest.php.

References BaseBlacklist\getInstance().

◆ spamProvider()

SpamBlacklistTest::spamProvider ( )

Definition at line 37 of file SpamBlacklistTest.php.

◆ tearDown()

SpamBlacklistTest::tearDown ( )
protected

Definition at line 89 of file SpamBlacklistTest.php.

◆ testSpam()

SpamBlacklistTest::testSpam ( $links,
$expected )

@dataProvider spamProvider

Definition at line 63 of file SpamBlacklistTest.php.

Member Data Documentation

◆ $blacklist

array SpamBlacklistTest::$blacklist = [ '\b01bags\.com\b', 'sytes\.net' ]
protected

Spam blacklist regexes.

Examples taken from:

See also
https://meta.wikimedia.org/wiki/Spam_blacklist
https://en.wikipedia.org/wiki/MediaWiki:Spam-blacklist

via Flow extension

Definition at line 24 of file SpamBlacklistTest.php.

◆ $spamFilter

SpamBlacklist SpamBlacklistTest::$spamFilter
protected

Definition at line 12 of file SpamBlacklistTest.php.

◆ $whitelist

array SpamBlacklistTest::$whitelist = [ 'a5b\.sytes\.net' ]
protected

Spam whitelist regexes.

Examples taken from:

See also
https://en.wikipedia.org/wiki/MediaWiki:Spam-whitelist

via Flow extension

Definition at line 35 of file SpamBlacklistTest.php.


The documentation for this class was generated from the following file: