Make WordPress Core


Ignore:
Timestamp:
10/17/2015 07:24:20 PM (9 years ago)
Author:
wonderboymusic
Message:

Unit Tests: WP_UnitTest_Generator_Sequence needs a static incrementer - otherwise, it assumes every test class is a reset, which it no longer is (it is now static).

While we're at it, remove unnecessary tearDown() code.

See #30017, #33968.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/basic.php

    r35172 r35244  
    66 */
    77class Tests_Basic extends WP_UnitTestCase {
    8     var $val;
    9 
    10     function setUp() {
    11         parent::setUp();
    12         $this->val = true;
    13     }
    14 
    15     function tearDown() {
    16         $this->val = false;
    17         parent::tearDown();
    18     }
    19 
    20     function test_true() {
    21         $this->assertTrue($this->val);
    22     }
    238
    249    function test_license() {
Note: See TracChangeset for help on using the changeset viewer.