assertConstraintPassed( $constraint ); } public function testFailure() { $constraint = new NewSectionMissingSubjectConstraint( 'new', '', false ); $this->assertConstraintFailed( $constraint, IEditConstraint::AS_SUMMARY_NEEDED ); } public function testNonNew() { $constraint = new NewSectionMissingSubjectConstraint( 'notnew', '', false ); $this->assertConstraintPassed( $constraint ); } }