summaryrefslogtreecommitdiff
path: root/tests/phpunit/includes/LicensesTest.php
blob: 212b3b3bf0a71cda0d982bb72b9362e0079991cd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<?php

class LicensesTest extends MediaWikiTestCase {

	function testLicenses() {
		$str = "
* Free licenses:
** GFDL|Debian disagrees
";

		$lc = new Licenses( array(
			'fieldname' => 'FooField',
			'type' => 'select',
			'section' => 'description',
			'id' => 'wpLicense',
			'label' => 'A label text', # Note can't test label-message because $wgOut is not defined
			'name' => 'AnotherName',
			'licenses' => $str,
		) );
		$this->assertThat( $lc, $this->isInstanceOf( 'Licenses' ) );
	}
}