Merge "Clean up database cloning for tests."
[lhc/web/wiklou.git] / tests / phpunit / includes / LicensesTest.php
index 0008a77..e467f3c 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-class LicensesTest extends PHPUnit_Framework_TestCase {
+class LicensesTest extends MediaWikiTestCase {
 
        function testLicenses() {
                $str = "
@@ -8,7 +8,15 @@ class LicensesTest extends PHPUnit_Framework_TestCase {
 ** GFDL|Debian disagrees
 ";
 
-               $lc = new Licenses( array( 'licenses' => $str ) );
+               $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' ) );
        }
 }